/* Serendipity Plugin Styles */
.serendipity-hub {
    direction: rtl;
    max-width: 600px;
    margin: 0 auto;
    padding: 20px;
    font-family: inherit;
}

.serendipity-container {
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    border-radius: 25px;
    padding: 30px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
    border: 1px solid rgba(255,255,255,0.2);
    backdrop-filter: blur(10px);
    position: relative;
    z-index: 1;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
}

.serendipity-header {
    text-align: center;
    margin-bottom: 30px;
}

.serendipity-title-main {
    font-size: 2.2em;
    font-weight: 700;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin: 0;
    text-shadow: 0 2px 4px rgba(0,0,0,0.1);
    font-family: inherit;
}

.serendipity-type-selector,
.serendipity-month-selector {
    margin-bottom: 25px;
    text-align: center;
}

.serendipity-label {
    display: block;
    font-size: 1.1em;
    font-weight: 600;
    color: #333;
    margin-bottom: 10px;
    font-family: inherit;
}

.serendipity-type-select,
.serendipity-month-select {
    width: 100%;
    max-width: 300px;
    padding: 12px 16px;
    border: 2px solid #e1e5e9;
    border-radius: 25px;
    font-size: 1em;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    transition: all 0.2s ease;
    outline: none;
    font-family: inherit !important;
    font-weight: inherit;
    color: inherit;
}

.serendipity-type-select:focus,
.serendipity-month-select:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.serendipity-type-select option,
.serendipity-month-select option {
    font-family: inherit !important;
    font-weight: inherit;
    color: inherit;
    background: #fff;
    padding: 8px 12px;
}

.serendipity-card {
    width: 100%;
    max-width: 500px;
    height: 500px;
    margin: 20px auto;
    perspective: 1000px;
}

.serendipity-card__inner {
    position: relative;
    width: 100%;
    height: 100%;
    transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    transform-style: preserve-3d;
}

.serendipity-card.is-flipped .serendipity-card__inner {
    transform: rotateY(180deg);
}

.serendipity-card__front,
.serendipity-card__back {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 20px;
    box-shadow: 0 15px 35px rgba(0,0,0,0.1);
    backface-visibility: hidden;
    padding: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.serendipity-card__front {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    text-align: center;
}

.serendipity-card__front-content {
    text-align: center;
}

.serendipity-card__icon {
    font-size: 4em;
    margin-bottom: 15px;
    animation: pulse 2s infinite;
}

.serendipity-card__front p {
    font-size: 1.3em;
    font-weight: 600;
    margin: 0;
}

.serendipity-card__back {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    color: #2c3e50;
    transform: rotateY(180deg);
    flex-direction: column;
    text-align: center;
    overflow-y: auto;
    border: 2px solid rgba(108, 117, 125, 0.2);
}

.serendipity-card--hidden {
    display: none;
}


.serendipity-fortune-content {
    font-size: 1.1em;
    line-height: 1.7;
    margin-bottom: 15px;
    text-shadow: 0 1px 2px rgba(0,0,0,0.2);
    font-family: inherit;
    padding: 25px;
    background: rgba(255,255,255,0.15);
    border-radius: 10px;
    color: #2c3e50;
    font-weight: 500;
    flex: 1;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    text-align: center;
    overflow-y: auto;
    max-height: 350px;
}

.serendipity-interactions {
    margin-top: 8px;
    text-align: center;
    padding: 10px;
    background: rgba(108, 117, 125, 0.1);
    border-radius: 10px;
    border: 1px solid rgba(108, 117, 125, 0.2);
    flex-shrink: 0;
}


.serendipity-reactions {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin-top: 20px;
}

.serendipity-react {
    background: linear-gradient(135deg, #6c5ce7 0%, #a29bfe 100%);
    border: 2px solid rgba(108, 92, 231, 0.3);
    border-radius: 50px;
    padding: 10px 20px;
    color: #fff;
    font-size: 1.1em;
    cursor: pointer;
    transition: all 0.2s ease;
    backdrop-filter: blur(10px);
    font-weight: 600;
}

.serendipity-react:hover {
    background: linear-gradient(135deg, #5f3dc4 0%, #9775fa 100%);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(108, 92, 231, 0.3);
}

.serendipity-count {
    margin-left: 8px;
    font-weight: 600;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

@media (max-width: 768px) {
    .serendipity-title-main {
        font-size: 1.8em;
    }
    
    .serendipity-card__front,
    .serendipity-card__back {
        min-height: 280px;
        padding: 20px;
    }
    
    .serendipity-fortune-title {
        font-size: 1.5em;
    }
}
