/**
 * Sticker Collector Widget Styles
 */

.angie-sticker-collector-wrapper {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    width: 100%;
    position: relative;
    justify-content: center; /* Center main container usually */
}

/* Responsive Stacking */
@media (max-width: 767px) {
    .angie-sticker-collector-wrapper {
        flex-direction: column;
        align-items: center;
    }
}

/* Mascot */
.angie-mascot-container {
    flex: 0 0 auto;
    max-width: 150px; 
    position: relative;
    cursor: default;
    transition: transform 0.2s ease;
}

/* Clickable Mode Styling */
.angie-sticker-collector-wrapper.interaction-click .angie-mascot-container {
    cursor: pointer;
}

.angie-sticker-collector-wrapper.interaction-click .angie-mascot-container:hover {
    transform: scale(1.05);
}

.angie-mascot-img {
    display: block;
    width: 100%;
    height: auto;
    object-fit: contain;
}

/* Click Hint Icon */
.angie-click-hint {
    position: absolute;
    bottom: 10px;
    right: -10px;
    background: #FFCC00;
    color: #fff;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
    font-size: 14px;
    animation: angie-bounce 2s infinite;
}

@keyframes angie-bounce {
    0%, 20%, 50%, 80%, 100% {transform: translateY(0);}
    40% {transform: translateY(-5px);}
    60% {transform: translateY(-3px);}
}


/* Speech Bubble */
.angie-speech-bubble {
    flex: 1;
    position: relative;
    background: #fff;
    padding: 25px;
    border-radius: 20px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    min-height: 200px;
    display: flex;
    flex-direction: column;
    /* Max-width is handled by JS/Control now */
}

/* Close Button */
.angie-close-bubble {
    position: absolute;
    top: 10px;
    right: 10px;
    background: none;
    border: none;
    cursor: pointer;
    color: #999;
    font-size: 18px;
    z-index: 5;
    padding: 5px;
}
.angie-close-bubble:hover {
    color: #333;
}

/* Bubble Tail (Pseudo-element) */
.angie-speech-bubble:after {
    content: '';
    position: absolute;
    width: 0;
    height: 0;
    border: 15px solid transparent;
}

/* Position: Right (Mascot Right, Bubble Left) */
.angie-sticker-collector-wrapper.position-right {
    flex-direction: row-reverse;
}
.angie-sticker-collector-wrapper.position-right .angie-speech-bubble:after {
    right: -28px; /* Slightly adjusted overlap */
    top: 40px;
    border-left-color: #fff; /* Injected color override handles this, but default here */
}

/* Position: Left (Mascot Left, Bubble Right) */
.angie-sticker-collector-wrapper.position-left .angie-speech-bubble:after {
    left: -28px;
    top: 40px;
    border-right-color: #fff;
}


/* Mobile override */
@media (max-width: 767px) {
    .angie-sticker-collector-wrapper.position-right,
    .angie-sticker-collector-wrapper.position-left {
        flex-direction: column;
    }

    .angie-speech-bubble {
        width: 100%;
        max-width: 100% !important; /* Force full width on mobile */
        margin-top: 20px;
    }

    .angie-speech-bubble:after {
        top: -28px !important;
        left: 50% !important;
        right: auto !important;
        bottom: auto !important;
        transform: translateX(-50%) !important;
        border-color: transparent !important;
        border-bottom-color: inherit !important;
        border-bottom-color: #000 !important; /* FIXED: Black tail on mobile */
    }
}


/* Filters Area */
.angie-filters-container {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.angie-search-box, 
.angie-family-box {
    flex: 1;
    min-width: 140px;
}

.angie-filter-input {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    transition: all 0.3s ease;
}

.angie-filter-input:focus {
    border-color: #888;
    outline: none;
    box-shadow: 0 0 0 2px rgba(0,0,0,0.05);
}

/* Results Area */
.angie-results-container {
    flex: 1;
    position: relative;
    min-height: 100px;
    display: flex;
    flex-direction: column;
}

.angie-sticker-results-grid {
    display: grid;
    /* Columns set by Widget Control (Default 2) */
    gap: 15px;
    width: 100%;
    margin-bottom: 15px;
}

.angie-sticker-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    text-decoration: none; /* In case it's div but inherited */
    color: inherit;
    padding: 10px;
    border-radius: 8px;
    transition: transform 0.2s;
    background: rgba(0,0,0,0.02);
    border: 1px solid transparent;
    cursor: default; /* No pointer cursor since not clickable */
}

/* Removed hover transform/shadow for non-clickable item, or keep for visual feedback? 
   User said "just display them", usually implies static. Let's keep slight hover for polish but no pointer. */
.angie-sticker-item:hover {
    transform: translateY(-2px);
    background: rgba(255,255,255,1);
    border-color: #eee;
}

.angie-sticker-image-wrapper {
    width: 100%;
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 8px;
    overflow: hidden;
    border-radius: 6px;
}

.angie-sticker-image-wrapper img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.angie-sticker-title {
    font-family: "Knicknack", Sans-serif; /* Hardcoded default fallback */
    font-size: 13px;
    font-weight: 600;
    margin: 0;
    line-height: 1.3;
}

.angie-initial-msg,
.angie-sticker-no-results {
    text-align: center;
    color: #888;
    font-style: italic;
    grid-column: 1 / -1;
    padding: 20px;
    font-size: 14px;
}

/* Pagination */
.angie-sticker-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin-top: auto;
    padding-top: 10px;
    border-top: 1px solid #eee;
}

.angie-pagination-btn {
    background: none;
    border: 1px solid #ddd;
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s;
}

.angie-pagination-btn:hover:not(:disabled) {
    background: #f5f5f5;
    border-color: #ccc;
}

.angie-pagination-btn:disabled,
.angie-pagination-btn.disabled {
    opacity: 0.5;
    cursor: not-allowed;
    border-color: #eee;
}

.angie-pagination-info {
    font-size: 12px;
    color: #666;
}

/* Loader */
.angie-loader {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255,255,255,0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    border-radius: 8px;
}

.angie-spinner {
    width: 30px;
    height: 30px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #3498db;
    border-radius: 50%;
    animation: angie-spin 1s linear infinite;
}

@keyframes angie-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}
