/**
 * Football Field Styles - dfwfan.com
 *
 * American football field layout with yard lines, end zones, and hash marks.
 */

/* ================================ */
/* APP LAYOUT                       */
/* ================================ */
.football-app {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background: var(--color-bg-primary);
}

/* ================================ */
/* HEADER / SCOREBOARD              */
/* ================================ */
.football-header {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 24px;
    padding: 16px 24px;
    background: var(--color-bg-header);
    border-bottom: 1px solid var(--color-border);
}

.football-score-team {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.football-team-label {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.football-team-label.home {
    color: var(--color-home);
}

.football-team-label.away {
    color: var(--color-away);
}

.football-score-controls {
    display: flex;
    align-items: center;
    gap: 8px;
}

.football-score-btn {
    width: 28px;
    height: 28px;
    border: 1px solid var(--color-border);
    background: var(--color-bg-header);
    color: var(--color-text);
    font-size: 1rem;
    cursor: pointer;
    border-radius: 4px;
    transition: background 0.15s;
}

.football-score-btn:hover {
    background: var(--alpha-light);
}

.football-score-display {
    font-size: 1.5rem;
    font-weight: 700;
    min-width: 40px;
    text-align: center;
    color: var(--color-text);
}

.football-score-divider {
    font-size: 1.5rem;
    color: var(--color-text-muted);
}

/* ================================ */
/* NAVIGATION                       */
/* ================================ */
.football-nav {
    background: var(--color-bg-primary);
    border-bottom: 1px solid var(--color-border);
    padding: 8px 24px;
}

.football-nav ul {
    display: flex;
    gap: 24px;
    list-style: none;
    margin: 0;
    padding: 0;
    justify-content: center;
}

.football-nav a {
    color: var(--color-text-muted);
    text-decoration: none;
    font-size: 0.8125rem;
    font-weight: 500;
    padding: 4px 0;
    border-bottom: 2px solid transparent;
    transition: color 0.15s, border-color 0.15s;
}

.football-nav a:hover,
.football-nav a:focus-visible {
    color: var(--color-text);
}

.football-nav a.active {
    color: var(--color-text);
    border-bottom-color: #8B4513;
}

/* ================================ */
/* FIELD WRAPPER                    */
/* ================================ */
.field-wrapper {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 24px;
    overflow: hidden;
}

.field {
    position: relative;
    width: 100%;
    max-width: 900px;
    aspect-ratio: 2.25 / 1;
    background: #2e7d32;
    border: 4px solid #fff;
    border-radius: 4px;
    overflow: hidden;
}

/* ================================ */
/* END ZONES                        */
/* ================================ */
.endzone {
    position: absolute;
    top: 0;
    bottom: 0;
    width: 10%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.endzone-home {
    left: 0;
    background: var(--color-home);
    border-right: 4px solid #fff;
}

.endzone-away {
    right: 0;
    background: var(--color-away);
    border-left: 4px solid #fff;
}

.endzone-label {
    font-size: 1.25rem;
    font-weight: 700;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    writing-mode: vertical-rl;
    text-orientation: mixed;
    transform: rotate(180deg);
}

.endzone-away .endzone-label {
    transform: rotate(0deg);
}

/* ================================ */
/* FIELD LINES                      */
/* ================================ */
.field-lines {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 10%;
    right: 10%;
}

.yard-line {
    position: absolute;
    top: 0;
    bottom: 0;
    width: 2px;
    background: rgba(255, 255, 255, 0.7);
}

.yard-line-10 {
    left: 12.5%;
}

.yard-line-20 {
    left: 25%;
}

.yard-line-30 {
    left: 37.5%;
}

.yard-line-40 {
    left: 50%;
}

.yard-line-50 {
    left: 50%;
    background: #fff;
    width: 3px;
}

.yard-line-40-away {
    left: 62.5%;
}

.yard-line-30-away {
    left: 75%;
}

.yard-line-20-away {
    left: 87.5%;
}

.yard-line-10-away {
    left: 100%;
    transform: translateX(-2px);
}

/* ================================ */
/* YARD NUMBERS                     */
/* ================================ */
.yard-numbers {
    position: absolute;
    top: 50%;
    left: 10%;
    right: 10%;
    transform: translateY(-50%);
    pointer-events: none;
}

.yard-num {
    position: absolute;
    transform: translateX(-50%);
    font-size: 1.5rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.5);
    font-family: var(--font-sans);
}

/* ================================ */
/* HASH MARKS                       */
/* ================================ */
.hash-marks {
    position: absolute;
    left: 10%;
    right: 10%;
    height: 2px;
}

.hash-marks-top {
    top: 30%;
    background: repeating-linear-gradient(to right,
            rgba(255, 255, 255, 0.3) 0px,
            rgba(255, 255, 255, 0.3) 4px,
            transparent 4px,
            transparent 20px);
}

.hash-marks-bottom {
    bottom: 30%;
    background: repeating-linear-gradient(to right,
            rgba(255, 255, 255, 0.3) 0px,
            rgba(255, 255, 255, 0.3) 4px,
            transparent 4px,
            transparent 20px);
}

/* ================================ */
/* TOKEN LAYER                      */
/* ================================ */
#token-layer {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
}

#token-layer>* {
    pointer-events: auto;
}

/* ================================ */
/* CONTROLS                         */
/* ================================ */
.football-controls {
    position: absolute;
    bottom: 12px;
    right: 12px;
    display: flex;
    gap: 8px;
}

.football-ctrl-btn {
    padding: 6px 12px;
    font-size: 0.75rem;
    font-weight: 600;
    background: rgba(0, 0, 0, 0.6);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.15s;
}

.football-ctrl-btn:hover {
    background: rgba(0, 0, 0, 0.8);
}

/* ================================ */
/* NOTICE                           */
/* ================================ */
.football-notice {
    padding: 16px 24px;
    background: var(--color-bg-header);
    border-top: 1px solid var(--color-border);
    text-align: center;
}

.football-notice p {
    margin: 0;
    font-size: 0.875rem;
    color: var(--color-text-muted);
}

.football-notice strong {
    color: var(--color-text);
}

/* ================================ */
/* RESPONSIVE                       */
/* ================================ */
@media (max-width: 768px) {
    .football-header {
        padding: 12px 16px;
        gap: 16px;
    }

    .football-score-display {
        font-size: 1.25rem;
    }

    .field-wrapper {
        padding: 16px;
    }

    .yard-num {
        font-size: 1rem;
    }

    .endzone-label {
        font-size: 0.875rem;
    }
}

@media (max-width: 480px) {
    .football-nav ul {
        gap: 12px;
    }

    .football-nav a {
        font-size: 0.75rem;
    }

    .yard-num {
        font-size: 0.75rem;
    }

    .football-controls {
        bottom: 8px;
        right: 8px;
    }

    .football-ctrl-btn {
        padding: 4px 8px;
        font-size: 0.6875rem;
    }
}
