/* ==========================================================================
   Poll Component - Modern Visitor Predictions UI
   Compatible with Dark & Light Mode
   ========================================================================== */

.Poll-Wrapper {
    background: linear-gradient(180deg, #151b26 0%, #10151f 100%);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 18px;
    padding: 22px 20px;
    margin: 16px auto;
    width: 95%;
    max-width: var(--Max-Size, 1180px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
    box-sizing: border-box;
    transition: background 0.3s ease, border-color 0.3s ease;
}

/* Header */
.Poll-Header {
    text-align: center;
    margin-bottom: 20px;
}

.Poll-Badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(0, 223, 162, 0.12);
    color: var(--Primary-A-Color, #00dfa2);
    border: 1px solid rgba(0, 223, 162, 0.25);
    padding: 4px 12px;
    border-radius: 999px;
    font-size: 11.5px;
    font-weight: 700;
    margin-bottom: 8px;
}

.Poll-Badge svg {
    flex-shrink: 0;
}

.Poll-Title {
    color: #f1f5f9;
    font-size: 17px;
    font-weight: 800;
    margin: 4px 0 6px 0;
    display: block;
    letter-spacing: -0.2px;
}

.Poll-Subtitle {
    color: #94a3b8;
    font-size: 12.5px;
    margin: 0;
    line-height: 1.5;
}

/* Voting Grid */
.Poll-Options {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

/* Individual Voting Card Button */
.Poll-Card-Btn {
    background: #1a2232;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    padding: 16px 10px;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
    color: #f1f5f9;
    outline: none;
    box-sizing: border-box;
    position: relative;
    overflow: hidden;
    user-select: none;
}

.Poll-Card-Btn:hover {
    transform: translateY(-3px);
    border-color: var(--Primary-A-Color, #00dfa2);
    background: #202b3f;
    box-shadow: 0 8px 20px rgba(0, 223, 162, 0.15);
}

.Poll-Card-Btn:active {
    transform: translateY(-1px);
}

.Poll-Logo-Wrap {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.04);
    border-radius: 50%;
    padding: 6px;
    box-sizing: border-box;
    transition: transform 0.2s ease;
}

.Poll-Card-Btn:hover .Poll-Logo-Wrap {
    transform: scale(1.08);
}

.Poll-Logo-Wrap img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.25));
}

.Poll-Logo-Wrap.poll-draw-icon {
    color: #94a3b8;
    background: rgba(148, 163, 184, 0.1);
}

.Poll-Btn-Info {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    width: 100%;
    text-align: center;
}

.Poll-Action-Text {
    font-size: 11px;
    color: #94a3b8;
    font-weight: 500;
}

.Poll-Team-Name {
    font-size: 13.5px;
    font-weight: 700;
    color: #ffffff;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    display: block;
}

.Poll-Vote-Action {
    display: inline-block;
    padding: 5px 14px;
    font-size: 11.5px;
    font-weight: 700;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.06);
    color: var(--Primary-A-Color, #00dfa2);
    border: 1px solid rgba(0, 223, 162, 0.2);
    margin-top: 2px;
    transition: all 0.2s ease;
}

.Poll-Card-Btn:hover .Poll-Vote-Action {
    background: var(--Primary-A-Color, #00dfa2);
    color: #0b0f17;
    font-weight: 800;
}

/* Results Display */
.Poll-Results {
    display: none;
    animation: pollFadeIn 0.35s ease-out;
}

@keyframes pollFadeIn {
    from {
        opacity: 0;
        transform: translateY(8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.Poll-Voted-Notice {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: rgba(0, 223, 162, 0.1);
    border: 1px solid rgba(0, 223, 162, 0.25);
    color: var(--Primary-A-Color, #00dfa2);
    padding: 8px 14px;
    border-radius: 12px;
    font-size: 12.5px;
    font-weight: 700;
    margin-bottom: 16px;
    text-align: center;
}

.Results-Cards-Grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-bottom: 14px;
}

.Result-Team-Card {
    background: #1a2232;
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 12px;
    padding: 12px 8px;
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 4px;
    transition: all 0.2s ease;
}

.Result-Team-Card.home { border-top: 3px solid #10b981; }
.Result-Team-Card.draw { border-top: 3px solid #64748b; }
.Result-Team-Card.away { border-top: 3px solid #f43f5e; }

.Result-Name {
    font-size: 12px;
    font-weight: 600;
    color: #94a3b8;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.Result-Perc {
    font-size: 19px;
    font-weight: 800;
    color: #ffffff;
}

.Result-Team-Card.home .Result-Perc { color: #10b981; }
.Result-Team-Card.draw .Result-Perc { color: #cbd5e1; }
.Result-Team-Card.away .Result-Perc { color: #f43f5e; }

/* Progress Container */
.Progress-Container {
    height: 12px;
    background: #0f141d;
    border-radius: 999px;
    display: flex;
    overflow: hidden;
    padding: 2px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.3);
}

.Progress-Segment {
    height: 100%;
    border-radius: 999px;
    transition: width 0.9s cubic-bezier(0.16, 1, 0.3, 1);
    min-width: 0;
}

.Progress-Segment.home {
    background: linear-gradient(90deg, #10b981, #06b6d4);
}
.Progress-Segment.draw {
    background: linear-gradient(90deg, #64748b, #475569);
}
.Progress-Segment.away {
    background: linear-gradient(90deg, #f43f5e, #e11d48);
}

/* ==========================================================================
   Light Mode Overrides for Poll
   ========================================================================== */
html.light-mode .Poll-Wrapper {
    background: #ffffff !important;
    border: 1px solid #e2e8f0 !important;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.05) !important;
}

html.light-mode .Poll-Badge {
    background: rgba(13, 148, 136, 0.1) !important;
    color: #0d9488 !important;
    border-color: rgba(13, 148, 136, 0.25) !important;
}

html.light-mode .Poll-Title {
    color: #0f172a !important;
}

html.light-mode .Poll-Subtitle {
    color: #64748b !important;
}

html.light-mode .Poll-Card-Btn {
    background: #f8fafc !important;
    border: 1px solid #e2e8f0 !important;
    color: #0f172a !important;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.02) !important;
}

html.light-mode .Poll-Card-Btn:hover {
    background: #ffffff !important;
    border-color: #0d9488 !important;
    box-shadow: 0 8px 20px rgba(13, 148, 136, 0.12) !important;
}

html.light-mode .Poll-Logo-Wrap {
    background: #ffffff !important;
    border: 1px solid #e2e8f0 !important;
}

html.light-mode .Poll-Logo-Wrap.poll-draw-icon {
    color: #64748b !important;
    background: #f1f5f9 !important;
}

html.light-mode .Poll-Action-Text {
    color: #64748b !important;
}

html.light-mode .Poll-Team-Name {
    color: #0f172a !important;
}

html.light-mode .Poll-Vote-Action {
    background: #ffffff !important;
    color: #0d9488 !important;
    border: 1px solid rgba(13, 148, 136, 0.3) !important;
}

html.light-mode .Poll-Card-Btn:hover .Poll-Vote-Action {
    background: #0d9488 !important;
    color: #ffffff !important;
}

html.light-mode .Poll-Voted-Notice {
    background: rgba(13, 148, 136, 0.08) !important;
    border-color: rgba(13, 148, 136, 0.25) !important;
    color: #0d9488 !important;
}

html.light-mode .Result-Team-Card {
    background: #f8fafc !important;
    border: 1px solid #e2e8f0 !important;
}

html.light-mode .Result-Team-Card.home { border-top: 3px solid #0d9488 !important; }
html.light-mode .Result-Team-Card.draw { border-top: 3px solid #94a3b8 !important; }
html.light-mode .Result-Team-Card.away { border-top: 3px solid #e11d48 !important; }

html.light-mode .Result-Name {
    color: #64748b !important;
}

html.light-mode .Result-Team-Card.home .Result-Perc { color: #0d9488 !important; }
html.light-mode .Result-Team-Card.draw .Result-Perc { color: #475569 !important; }
html.light-mode .Result-Team-Card.away .Result-Perc { color: #e11d48 !important; }

html.light-mode .Progress-Container {
    background: #e2e8f0 !important;
    border-color: #cbd5e1 !important;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.06) !important;
}

/* ==========================================================================
   Responsiveness
   ========================================================================== */
@media (max-width: 640px) {
    .Poll-Wrapper {
        padding: 16px 12px;
        border-radius: 14px;
        margin: 10px auto;
        width: 95%;
    }

    .Poll-Title {
        font-size: 15px;
    }

    .Poll-Subtitle {
        font-size: 11.5px;
    }

    .Poll-Options {
        gap: 8px;
    }

    .Poll-Card-Btn {
        padding: 12px 6px;
        border-radius: 12px;
        gap: 6px;
    }

    .Poll-Logo-Wrap {
        width: 36px;
        height: 36px;
        padding: 4px;
    }

    .Poll-Team-Name {
        font-size: 11.5px;
    }

    .Poll-Vote-Action {
        font-size: 10.5px;
        padding: 3px 8px;
    }

    .Results-Cards-Grid {
        gap: 6px;
    }

    .Result-Team-Card {
        padding: 8px 4px;
    }

    .Result-Name {
        font-size: 10.5px;
    }

    .Result-Perc {
        font-size: 16px;
    }
}
