/* ========================================
   MATCHING PAGE - FINAL REDESIGN
   ======================================== */

/* Container */
.matching-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px 80px;
}

/* Header */
.matching-header {
    text-align: center;
    margin-bottom: 40px;
    padding-top: 20px;
}

.matching-header h1 {
    font-family: 'Playfair Display', serif;
    font-size: 3rem;
    color: #ffffff;
    margin: 0 0 15px;
    font-weight: 700;
}

.matching-header .highlight {
    color: #fdd56a;
    background: linear-gradient(135deg, #fdd56a 0%, #ffb84d 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.matching-header .subtitle {
    font-size: 1.1rem;
    color: var(--text-muted);
    line-height: 1.6;
    max-width: 700px;
    margin: 0 auto;
}

/* Selection Wrapper - Single Row */
.selection-wrapper-single {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    margin-bottom: 35px;
    background: linear-gradient(135deg, rgba(42, 42, 56, 0.4) 0%, rgba(26, 26, 46, 0.6) 100%);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 20px 30px;
    backdrop-filter: blur(10px);
    flex-wrap: wrap;
}

.selector-group {
    display: flex;
    align-items: center;
    gap: 12px;
}

.person-label-inline {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #fdd56a;
    font-weight: 600;
    font-size: 1rem;
    white-space: nowrap;
}

.person-label-inline i {
    font-size: 1.1rem;
}

.zodiac-select-compact,
.gender-select-compact {
    padding: 10px 14px;
    background: rgba(30, 30, 47, 0.8);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    color: #ffffff;
    font-size: 0.95rem;
    font-family: var(--font-main);
    cursor: pointer;
    transition: all 0.3s;
    outline: none;
}

.zodiac-select-compact {
    min-width: 140px;
}

.gender-select-compact {
    min-width: 100px;
}

.zodiac-select-compact:hover,
.gender-select-compact:hover {
    border-color: #fdd56a;
    background: rgba(253, 213, 106, 0.1);
}

.zodiac-select-compact:focus,
.gender-select-compact:focus {
    border-color: #fdd56a;
    box-shadow: 0 0 0 3px rgba(253, 213, 106, 0.2);
}

.zodiac-select-compact option,
.gender-select-compact option {
    background: #1a1a2e;
    color: #ffffff;
    padding: 10px;
}

/* VS Divider Inline */
.vs-divider-inline {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #fdd56a 0%, #ffb84d 100%);
    border-radius: 50%;
    font-weight: 700;
    font-size: 1.1rem;
    color: #0f0f1a;
    box-shadow: 0 5px 20px rgba(253, 213, 106, 0.4);
    flex-shrink: 0;
}

/* Match Type Buttons */
.match-type-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 50px;
}

.btn-match-type {
    background: linear-gradient(135deg, rgba(42, 42, 56, 0.6) 0%, rgba(26, 26, 46, 0.8) 100%);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 25px 30px;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    text-align: center;
    font-family: var(--font-main);
    backdrop-filter: blur(10px);
    position: relative;
    overflow: hidden;
}

.btn-match-type::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(253, 213, 106, 0.1), transparent);
    transition: left 0.5s;
}

.btn-match-type:hover::before {
    left: 100%;
}

.btn-match-type i {
    font-size: 2.5rem;
    color: var(--text-muted);
    transition: all 0.3s;
}

.btn-match-type span {
    font-size: 1.2rem;
    font-weight: 700;
    color: #ffffff;
    transition: all 0.3s;
}

.btn-match-type small {
    font-size: 0.9rem;
    color: var(--text-muted);
    font-weight: 400;
}

.btn-match-type:hover {
    border-color: #fdd56a;
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(253, 213, 106, 0.2);
}

.btn-match-type:hover i {
    color: #fdd56a;
    transform: scale(1.1);
}

.btn-match-type.active {
    background: linear-gradient(135deg, rgba(253, 213, 106, 0.2) 0%, rgba(255, 184, 77, 0.15) 100%);
    border-color: #fdd56a;
    box-shadow: 0 5px 25px rgba(253, 213, 106, 0.3);
}

.btn-match-type.active i {
    color: #fdd56a;
}

.btn-match-type.active span {
    color: #fdd56a;
}

/* Results Container - New Unified Design */
.results-container {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

/* Main Result Card */
.main-result-card {
    background: linear-gradient(135deg, rgba(42, 42, 56, 0.6) 0%, rgba(26, 26, 46, 0.8) 100%);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 35px;
    backdrop-filter: blur(10px);
}

.result-header {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.header-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #fdd56a 0%, #ffb84d 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.header-icon i {
    font-size: 1.8rem;
    color: #0f0f1a;
}

.header-text h2 {
    font-size: 1.8rem;
    color: #ffffff;
    margin: 0 0 5px;
    font-weight: 700;
}

.zodiac-pair-display {
    font-size: 1.1rem;
    color: #fdd56a;
    margin: 0;
    font-weight: 600;
}

/* Score Section */
.score-section {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 40px;
    align-items: center;
}

.score-visual {
    display: flex;
    justify-content: center;
}

.score-circle-main {
    position: relative;
    width: 200px;
    height: 200px;
}

.score-circle-main svg {
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}

.score-circle-main .score-bg {
    fill: none;
    stroke: rgba(255, 255, 255, 0.1);
    stroke-width: 12;
}

.score-circle-main .score-fill {
    fill: none;
    stroke: url(#scoreGradient);
    stroke-width: 12;
    stroke-linecap: round;
    transition: stroke-dashoffset 1s ease;
}

.score-circle-main .score-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
}

.score-circle-main .score-number {
    display: block;
    font-size: 3rem;
    font-weight: 700;
    color: #fdd56a;
    line-height: 1;
    margin-bottom: 5px;
}

.score-circle-main .score-label {
    display: block;
    font-size: 1rem;
    color: #4caf50;
    font-weight: 600;
}

.score-description h3 {
    font-size: 1.3rem;
    color: #ffffff;
    margin: 0 0 15px;
    font-weight: 600;
}

.score-description p {
    color: var(--text-muted);
    line-height: 1.7;
    margin: 0 0 20px;
}

.compatibility-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
}

.tag i {
    font-size: 0.85rem;
}

.tag-positive {
    background: rgba(76, 175, 80, 0.15);
    border: 1px solid rgba(76, 175, 80, 0.3);
    color: #4caf50;
}

.tag-neutral {
    background: rgba(255, 193, 7, 0.15);
    border: 1px solid rgba(255, 193, 7, 0.3);
    color: #ffc107;
}

/* Detailed Analysis Card */
.detailed-analysis-card {
    background: linear-gradient(135deg, rgba(42, 42, 56, 0.6) 0%, rgba(26, 26, 46, 0.8) 100%);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 0;
    backdrop-filter: blur(10px);
    overflow: hidden;
}

.premium-header {
    padding: 30px;
    text-align: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.premium-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, #fdd56a 0%, #ffb84d 100%);
    color: #0f0f1a;
    padding: 8px 20px;
    border-radius: 20px;
    font-weight: 700;
    font-size: 0.85rem;
    letter-spacing: 1px;
    margin-bottom: 15px;
}

.premium-badge i {
    font-size: 1rem;
}

.premium-header h3 {
    font-size: 1.6rem;
    color: #ffffff;
    margin: 0 0 10px;
    font-weight: 700;
}

.premium-header p {
    color: var(--text-muted);
    margin: 0;
    font-size: 1rem;
}

/* Premium Content Preview */
.premium-content-preview {
    padding: 30px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.preview-section {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 20px;
    align-items: center;
    padding: 20px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    transition: all 0.3s;
}

.preview-section:hover {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(253, 213, 106, 0.2);
}

.section-icon {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, rgba(253, 213, 106, 0.2) 0%, rgba(255, 184, 77, 0.15) 100%);
    border: 1px solid rgba(253, 213, 106, 0.3);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.section-icon i {
    font-size: 1.5rem;
    color: #fdd56a;
}

.section-info h4 {
    font-size: 1.1rem;
    color: #ffffff;
    margin: 0 0 5px;
    font-weight: 600;
}

.section-info p {
    color: var(--text-muted);
    margin: 0;
    font-size: 0.9rem;
}

.lock-indicator {
    width: 40px;
    height: 40px;
    background: rgba(253, 213, 106, 0.1);
    border: 1px solid rgba(253, 213, 106, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.lock-indicator i {
    font-size: 1.1rem;
    color: #fdd56a;
}

/* Unlock Button */
.btn-unlock-main {
    background: linear-gradient(135deg, #fdd56a 0%, #ffb84d 100%);
    border: none;
    padding: 16px 40px;
    margin: 0 30px 30px;
    border-radius: 50px;
    cursor: pointer;
    color: #0f0f1a;
    font-weight: 700;
    font-size: 1.1rem;
    transition: all 0.3s;
    font-family: var(--font-main);
    box-shadow: 0 5px 25px rgba(253, 213, 106, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.btn-unlock-main:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 35px rgba(253, 213, 106, 0.6);
}

.btn-unlock-main i {
    font-size: 1.2rem;
}

/* Conflict Analysis Card */
.conflict-analysis-card {
    background: linear-gradient(135deg, rgba(42, 42, 56, 0.6) 0%, rgba(26, 26, 46, 0.8) 100%);
    border: 1px solid rgba(255, 107, 107, 0.2);
    border-radius: 20px;
    padding: 0;
    backdrop-filter: blur(10px);
    overflow: hidden;
}

.conflict-header-main {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 20px;
    align-items: center;
    padding: 30px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.conflict-icon-main {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, rgba(255, 107, 107, 0.2) 0%, rgba(238, 90, 111, 0.15) 100%);
    border: 2px solid rgba(255, 107, 107, 0.3);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.conflict-icon-main i {
    font-size: 1.8rem;
    color: #ff6b6b;
}

.conflict-text-main h3 {
    font-size: 1.5rem;
    color: #ffffff;
    margin: 0 0 5px;
    font-weight: 700;
}

.conflict-text-main p {
    color: var(--text-muted);
    margin: 0;
    font-size: 1rem;
}

.premium-badge-small {
    display: flex;
    align-items: center;
    gap: 6px;
    background: linear-gradient(135deg, #fdd56a 0%, #ffb84d 100%);
    color: #0f0f1a;
    padding: 6px 14px;
    border-radius: 16px;
    font-weight: 700;
    font-size: 0.75rem;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

.premium-badge-small i {
    font-size: 0.85rem;
}

/* Conflict Preview */
.conflict-preview {
    padding: 30px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.conflict-item-preview {
    display: grid;
    grid-template-columns: 200px 1fr auto;
    gap: 20px;
    align-items: center;
    padding: 20px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    transition: all 0.3s;
}

.conflict-item-preview:hover {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(255, 107, 107, 0.2);
}

.conflict-bar-wrapper {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.conflict-bar-bg {
    height: 30px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    overflow: hidden;
    position: relative;
}

.conflict-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #ff6b6b 0%, #ee5a6f 100%);
    border-radius: 15px;
    transition: width 1s ease;
}

.conflict-percentage {
    font-size: 0.85rem;
    color: #ff6b6b;
    font-weight: 600;
    text-align: center;
}

.conflict-details h5 {
    font-size: 1.1rem;
    color: #ffffff;
    margin: 0 0 5px;
    font-weight: 600;
}

.conflict-details p {
    color: var(--text-muted);
    margin: 0;
    font-size: 0.9rem;
}

/* Responsive Design */
@media (max-width: 968px) {
    .selection-wrapper-single {
        flex-direction: column;
        align-items: stretch;
    }

    .selector-group {
        flex-wrap: wrap;
        justify-content: center;
    }

    .vs-divider-inline {
        margin: 10px auto;
    }

    .match-type-buttons {
        grid-template-columns: 1fr;
    }

    .score-section {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .score-visual {
        justify-content: center;
    }

    .compatibility-tags {
        justify-content: center;
    }

    .preview-section {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .section-icon,
    .lock-indicator {
        margin: 0 auto;
    }

    .conflict-header-main {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .conflict-icon-main,
    .premium-badge-small {
        margin: 0 auto;
    }

    .conflict-item-preview {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .conflict-bar-wrapper {
        order: -1;
    }

    .lock-indicator {
        order: 1;
    }
}

@media (max-width: 768px) {
    .matching-header h1 {
        font-size: 2rem;
    }

    .matching-header .subtitle {
        font-size: 1rem;
    }

    .score-circle-main {
        width: 150px;
        height: 150px;
    }

    .score-circle-main .score-number {
        font-size: 2.5rem;
    }
}

/* Add gradient definition for SVG */
@supports (background-clip: text) or (-webkit-background-clip: text) {
    .matching-header .highlight {
        background: linear-gradient(135deg, #fdd56a 0%, #ffb84d 100%);
        -webkit-background-clip: text;
        -webkit-text-fill-color: transparent;
        background-clip: text;
    }
}