:root {
    --primary: #FF4D00;
    --primary-glow: rgba(255, 77, 0, 0.4);
    --accent: #00D4FF;
    --accent-glow: rgba(0, 212, 255, 0.3);
    --success: #00ff88;
    --success-glow: rgba(0, 255, 136, 0.3);
    --bg-dark: #0a0a0a;
    --bg-card: rgba(20, 20, 20, 0.9);
    --text-light: #ffffff;
    --text-dim: #a0a0a0;
    --glass: rgba(255, 255, 255, 0.05);
    --glass-border: rgba(255, 255, 255, 0.1);
    --font-main: 'Outfit', sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html,
body {
    height: 100%;
}

body {
    font-family: var(--font-main);
    background-color: var(--bg-dark);
    color: var(--text-light);
    overflow-x: hidden;
}

/* Background Glow */
.background-glow {
    position: fixed;
    top: -30%;
    left: -20%;
    width: 80vw;
    height: 80vh;
    background: radial-gradient(circle, rgba(255, 77, 0, 0.1) 0%, transparent 60%);
    filter: blur(100px);
    z-index: -1;
}

/* Header */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 5%;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    background: rgba(10, 10, 10, 0.9);
    backdrop-filter: blur(10px);
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
}

.logo span {
    font-weight: 800;
    font-size: 1.3rem;
    letter-spacing: 2px;
    background: linear-gradient(45deg, #fff, var(--text-dim));
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.logo-icon {
    height: 40px;
    width: auto;
    border-radius: 8px;
    /* Optional: adds a slight finish to the icon */
}

nav a {
    color: var(--text-dim);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
}

/* ==================== */
/* MAIN APP SECTION */
/* ==================== */
#app-section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 100vh;
    padding-top: 60px;
}

/* Result Mode - Full width centered */
#app-section.result-mode {
    grid-template-columns: 1fr;
    justify-items: center;
}

#app-section.result-mode .create-panel {
    width: 100%;
    max-width: 900px;
    padding: 2rem 3rem;
}

#app-section.result-mode .create-card {
    max-width: 100%;
    padding: 2.5rem 3rem;
}

/* Left Panel - Showcase */
.showcase-panel {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 2rem 4rem;
    background: linear-gradient(135deg, rgba(20, 20, 20, 0.5) 0%, transparent 100%);
}

.showcase-panel h1 {
    font-size: 2.5rem;
    line-height: 1.2;
    margin-bottom: 0.75rem;
    font-weight: 800;
}

.gradient-text {
    background: linear-gradient(90deg, var(--accent), var(--success));
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.legend-text {
    color: #ffffff;
}

/* Sport Cycle Animation in Header */
.sport-cycle-container {
    display: inline-block;
    position: relative;
    min-width: 180px;
    white-space: nowrap;
}

.sport-cycle {
    display: inline-block;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: sportFadeIn 1s ease-in-out;
    white-space: nowrap;
}

@keyframes sportFadeIn {
    0% {
        opacity: 0;
        transform: translateY(10px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.tagline {
    color: var(--text-dim);
    font-size: 1.1rem;
    margin-bottom: 2rem;
}

/* Before/After Container */
.before-after-container {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-bottom: 1rem;
}

.ba-card {
    position: relative;
    width: 260px;
    height: 360px;
    border-radius: 16px;
    overflow: hidden;
    border: 3px solid var(--glass-border);
    background: var(--glass);
    transition: all 0.3s ease;
}

.ba-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.ba-card.before {
    border-color: var(--glass-border);
}

.ba-card.after {
    border-color: var(--primary);
    box-shadow: 0 0 40px var(--primary-glow), 0 10px 40px rgba(0, 0, 0, 0.5);
}

.ba-card.after .ba-glow {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(255, 77, 0, 0.2), transparent 50%);
    pointer-events: none;
}

.ba-label {
    position: absolute;
    bottom: 12px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.8);
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    white-space: nowrap;
}

.ba-arrow {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    color: var(--primary);
    font-size: 1.5rem;
}

.arrow-line {
    width: 40px;
    height: 3px;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    border-radius: 2px;
}

.showcase-note {
    color: var(--text-dim);
    font-size: 0.9rem;
}

#sport-label {
    color: var(--accent);
    font-weight: 600;
}

/* Right Panel - Create */
.create-panel {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    background: rgba(0, 0, 0, 0.3);
}

.create-card {
    background: var(--bg-card);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 2rem;
    width: 100%;
    max-width: 480px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.create-card h2 {
    font-size: 1.6rem;
    margin-bottom: 1.5rem;
    text-align: center;
}

/* Upload Zone */
.upload-zone {
    border: 2px dashed var(--glass-border);
    border-radius: 16px;
    padding: 2.5rem 1.5rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    margin-bottom: 1.25rem;
    background: var(--glass);
}

.upload-zone:hover {
    border-color: var(--primary);
    background: rgba(255, 77, 0, 0.05);
}

.upload-zone.has-file {
    border-color: var(--success);
    border-style: solid;
}

.upload-icon {
    font-size: 3rem;
    margin-bottom: 0.5rem;
}

#file-name {
    display: block;
    font-weight: 600;
    font-size: 1.1rem;
    margin-bottom: 0.25rem;
}

.upload-hint {
    font-size: 0.85rem;
    color: var(--text-dim);
}

/* Sport Selector - Grid for 10 sports */
.sport-selector {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.sport-option {
    display: block;
}

.sport-option input {
    display: none;
}

.sport-pill {
    text-align: center;
    padding: 0.6rem 0.3rem;
    border-radius: 10px;
    background: var(--glass);
    border: 2px solid var(--glass-border);
    cursor: pointer;
    font-weight: 600;
    font-size: 0.75rem;
    transition: all 0.3s;
    white-space: nowrap;
}

.sport-pill:hover {
    border-color: rgba(255, 77, 0, 0.5);
}

.sport-option input:checked+.sport-pill {
    border-color: var(--primary);
    background: rgba(255, 77, 0, 0.15);
    box-shadow: 0 0 15px var(--primary-glow);
}

/* Generate Button */
.generate-btn {
    width: 100%;
    padding: 1.1rem;
    border: none;
    border-radius: 12px;
    background: linear-gradient(90deg, var(--primary), #FF7B00);
    color: white;
    font-size: 1.15rem;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 4px 25px var(--primary-glow);
    transition: transform 0.2s, box-shadow 0.2s;
}

.generate-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 30px var(--primary-glow);
}

.generate-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.create-note {
    text-align: center;
    color: var(--text-dim);
    font-size: 0.85rem;
    margin-top: 1rem;
}

/* Debug Preview Button */
.preview-btn {
    width: 100%;
    padding: 0.5rem;
    margin-top: 0.75rem;
    border: 1px dashed var(--glass-border);
    border-radius: 8px;
    background: transparent;
    color: var(--text-dim);
    font-size: 0.75rem;
    cursor: pointer;
    opacity: 0.6;
    transition: all 0.2s;
}

.preview-btn:hover {
    opacity: 1;
    border-color: var(--accent);
    color: var(--accent);
}

/* Loading State */
#loading-state {
    padding: 4rem 2rem;
    text-align: center;
}

.spinner {
    width: 60px;
    height: 60px;
    border: 4px solid var(--glass-border);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 1.5rem;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.loading-visual h3 {
    margin-bottom: 0.5rem;
}

.loading-subtext {
    color: var(--text-dim);
}

/* ==================== */
/* RESULT STATE - PRICING */
/* ==================== */
#result-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2rem;
    text-align: center;
}

.result-header {
    text-align: center;
    margin-bottom: 1.5rem;
}

.header-top {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1.5rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.result-header h2 {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 0;
    color: var(--text);
}

/* Credits Display - Plain text style */
.credits-display {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
}

.credits-icon {
    font-size: 0.9rem;
    color: var(--primary);
}

.credits-count {
    font-size: 1rem;
    font-weight: 700;
    color: white;
}

.credits-label {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.7);
}

/* Result Actions */
.result-actions {
    display: flex;
    justify-content: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.action-btn {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.6rem 1rem;
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.05);
    color: var(--text);
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.action-btn:hover {
    border-color: var(--primary);
    background: rgba(255, 107, 53, 0.1);
}

.action-btn svg {
    width: 16px;
    height: 16px;
}

.create-new-btn:hover {
    border-color: var(--success);
    background: rgba(0, 212, 170, 0.1);
}

.edit-btn.active {
    border-color: var(--primary);
    background: rgba(255, 107, 53, 0.15);
}

/* Edit Panel - Overlay on top of image */
.result-preview-container {
    position: relative;
}

.edit-panel {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    background: rgba(0, 0, 0, 0.5);
    border: none;
    border-bottom: 1px solid var(--glass-border);
    border-radius: 0;
    padding: 1.25rem;
    backdrop-filter: blur(15px);
}

.edit-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.edit-title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text);
}

.edit-credits-remaining {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.6);
}

.edit-credits-remaining span {
    color: var(--primary);
    font-weight: 700;
}

/* Edit Loading Overlay */
.edit-loading-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.85);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    color: var(--text);
    font-size: 0.9rem;
    z-index: 50;
}

.edit-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--glass-border);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.result-preview {
    position: relative;
    overflow: hidden;
}

.edit-options {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.edit-label {
    display: block;
    font-size: 0.75rem;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.4rem;
}

.edit-prompt-input {
    width: 100%;
    min-height: 60px;
    padding: 0.75rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    color: var(--text);
    font-size: 0.85rem;
    font-family: inherit;
    resize: vertical;
    transition: border-color 0.2s;
}

.edit-prompt-input:focus {
    outline: none;
    border-color: var(--primary);
}

.edit-prompt-input::placeholder {
    color: var(--text-dim);
    opacity: 0.6;
}

.style-buttons {
    display: flex;
    gap: 0.5rem;
}

.style-btn {
    flex: 1;
    padding: 0.6rem 1rem;
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    background: transparent;
    color: var(--text);
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.style-btn:hover {
    border-color: var(--text-dim);
}

.style-btn.active {
    border-color: var(--primary);
    background: rgba(255, 107, 53, 0.15);
    color: var(--primary);
}

.apply-edit-btn {
    width: 100%;
    padding: 0.75rem;
    background: var(--primary);
    border: none;
    border-radius: 8px;
    color: white;
    font-size: 0.9rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
}

.apply-edit-btn:hover {
    background: #ff8a50;
    transform: translateY(-1px);
}

.edit-cost {
    font-weight: 400;
    opacity: 0.8;
    font-size: 0.8rem;
}

/* Result Content */
.result-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2rem;
    width: 100%;
}

.result-preview-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    width: 100%;
}

.result-preview {
    max-width: 450px;
    width: 100%;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.result-preview img {
    width: 100%;
    display: block;
}

/* Iteration History */
.iteration-history {
    width: 100%;
    max-width: 450px;
}

.history-label {
    display: block;
    font-size: 0.7rem;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.5rem;
    text-align: center;
}

.history-thumbnails {
    display: flex;
    gap: 0.5rem;
    justify-content: center;
    flex-wrap: wrap;
}

.history-thumbnail {
    width: 60px;
    height: 60px;
    border-radius: 6px;
    overflow: hidden;
    border: 2px solid transparent;
    cursor: pointer;
    transition: all 0.2s;
    opacity: 0.6;
}

.history-thumbnail:hover {
    opacity: 1;
    border-color: var(--text-dim);
}

.history-thumbnail.active {
    opacity: 1;
    border-color: var(--primary);
    box-shadow: 0 0 10px var(--primary-glow);
}

.history-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.history-thumbnail .version-number {
    display: none;
}

.format-title {
    text-align: center;
    font-size: 1.1rem;
    margin-bottom: 1rem;
    color: var(--text-dim);
}

/* Pricing Section */
.pricing-section {
    width: 100%;
}

/* Pricing Cards - 3 column layout (first row 3, second row 2 centered) */
.pricing-cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin-bottom: 1.5rem;
}

/* Second row cards - centered */
.pricing-cards .pricing-card:nth-child(4),
.pricing-cards .pricing-card:nth-child(5) {
    grid-column: span 1;
}

/* Center the last 2 cards */
.pricing-cards::after {
    content: '';
    grid-column: span 1;
}

.pricing-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    background: var(--glass);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 1.5rem 1rem;
    text-align: center;
    position: relative;
    cursor: pointer;
    transition: all 0.3s;
}

.pricing-card:hover {
    border-color: var(--primary);
    transform: translateY(-2px);
}

.pricing-card.selected {
    border-color: var(--primary);
    background: rgba(255, 107, 53, 0.1);
    box-shadow: 0 0 20px var(--primary-glow);
}

/* Digital card special styling */
.digital-card {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.08) 0%, rgba(255, 255, 255, 0.02) 100%);
}

/* Legend card special styling */
.legend-card {
    border-color: rgba(255, 215, 0, 0.3);
}

.legend-card:hover {
    border-color: rgba(255, 215, 0, 0.6);
}

.card-badge {
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    white-space: nowrap;
}

.card-badge.popular {
    background: var(--success);
    color: #000;
}

.card-badge.gift {
    background: var(--primary);
    color: #fff;
}

.card-badge.legend {
    background: linear-gradient(90deg, #FFD700, #FFA500);
    color: #000;
}

.card-icon-svg {
    color: var(--text-dim);
    margin-bottom: 0.5rem;
}

.card-icon-svg svg {
    width: 28px;
    height: 28px;
}

.card-icon-text {
    font-size: 1.2rem;
    font-weight: 800;
    color: var(--text-dim);
    margin-bottom: 0.5rem;
    letter-spacing: -1px;
}

.card-info {
    margin-bottom: 0.5rem;
}

.pricing-card h4 {
    font-size: 1.1rem;
    margin-bottom: 0.25rem;
    font-weight: 700;
}

.card-size-label {
    font-size: 0.85rem;
    color: var(--text-dim);
    margin-bottom: 0.5rem;
}

.card-size {
    font-size: 0.9rem;
    color: var(--text-dim);
    margin-bottom: 0.5rem;
}

.card-desc {
    font-size: 0.8rem;
    color: var(--text-dim);
    margin-bottom: 0.75rem;
    line-height: 1.4;
}

/* Resolution Selector */
.resolution-selector {
    width: 100%;
    margin-bottom: 0.75rem;
}

.resolution-label {
    display: block;
    font-size: 0.7rem;
    color: var(--text-dim);
    margin-bottom: 0.4rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.resolution-select {
    width: 100%;
    padding: 0.6rem 0.8rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    color: var(--text);
    font-size: 0.8rem;
    cursor: pointer;
    transition: border-color 0.2s;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%23888' viewBox='0 0 16 16'%3E%3Cpath d='M8 11L3 6h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.8rem center;
}

.resolution-select:hover,
.resolution-select:focus {
    border-color: var(--primary);
    outline: none;
}

.resolution-select option {
    background: var(--background);
    color: var(--text);
}

.card-resolution {
    font-size: 0.7rem;
    color: var(--primary);
    font-weight: 600;
    margin-bottom: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.card-price {
    margin-bottom: 0.5rem;
}

.price-old {
    text-decoration: line-through;
    color: var(--text-dim);
    font-size: 0.9rem;
}

.price-current {
    font-size: 2rem;
    font-weight: 800;
    color: var(--text);
    display: block;
}

.card-features {
    list-style: none;
    text-align: left;
    font-size: 0.7rem;
    color: var(--text-dim);
    margin-bottom: 0.5rem;
    padding: 0;
    width: 100%;
}

.card-features li {
    margin-bottom: 0.2rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.card-features .check {
    color: var(--success);
    font-weight: bold;
}

.card-shipping {
    font-size: 0.7rem;
    color: var(--success);
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.card-bonus {
    font-size: 0.65rem;
    color: var(--primary);
    margin-bottom: 0.75rem;
}

.card-btn {
    width: 100%;
    padding: 0.7rem 1rem;
    margin-top: auto;
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    background: transparent;
    color: white;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.card-btn:hover {
    background: white;
    color: #000;
}

.card-btn.primary-btn {
    background: var(--text);
    color: var(--background);
    border-color: var(--text);
}

.card-btn.primary-btn:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
}

/* Buy Button */
.buy-btn {
    width: 100%;
    padding: 1rem;
    border: none;
    border-radius: 12px;
    background: linear-gradient(90deg, var(--accent), #00a8cc);
    color: white;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    margin-bottom: 0.75rem;
    box-shadow: 0 4px 20px var(--accent-glow);
    transition: transform 0.2s, box-shadow 0.2s;
}

.buy-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px var(--accent-glow);
}

.try-again-btn {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--glass-border);
    border-radius: 10px;
    background: transparent;
    color: var(--text-dim);
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.try-again-btn:hover {
    border-color: var(--text-dim);
    color: white;
}

/* Hidden class */
.hidden {
    display: none !important;
}

/* ==================== */
/* RESPONSIVE */
/* ==================== */

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Hide scrollbar on pricing cards but keep functionality */
.pricing-cards::-webkit-scrollbar {
    display: none;
}

.pricing-cards {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

/* === Tablet Breakpoint (1000px) === */
@media (max-width: 1000px) {
    #app-section {
        grid-template-columns: 1fr;
    }

    .showcase-panel {
        padding: 1.5rem 2rem;
        text-align: center;
    }

    .showcase-panel h1 {
        font-size: 2rem;
    }

    .before-after-container {
        justify-content: center;
    }

    .ba-card {
        width: 180px;
        height: 250px;
    }
}

/* === Medium Tablet Breakpoint (768px) === */
@media (max-width: 768px) {

    /* Sport selector - 4 columns on tablet */
    .sport-selector {
        grid-template-columns: repeat(4, 1fr);
        gap: 0.4rem;
    }

    .sport-pill {
        padding: 0.5rem 0.2rem;
        font-size: 0.65rem;
    }

    /* Pricing cards - horizontal scroll on tablet and below */
    .pricing-section {
        width: calc(100% + 2rem);
        margin-left: -1rem;
        padding: 0 1rem;
    }

    .pricing-cards {
        display: flex;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        -webkit-overflow-scrolling: touch;
        gap: 0.75rem;
        padding: 0.5rem 0 1rem;
        grid-template-columns: none;
    }

    .pricing-cards::after {
        content: none;
    }

    .pricing-card {
        flex: 0 0 260px;
        min-width: 260px;
        scroll-snap-align: center;
        padding: 1.25rem;
    }

    .price-current {
        font-size: 1.8rem;
    }

    .card-features {
        font-size: 0.75rem;
    }

    .card-btn {
        min-height: 44px;
    }
}

/* === Mobile Breakpoint (600px) === */
@media (max-width: 600px) {

    /* Header improvements */
    header {
        padding: 0.75rem 4%;
    }

    .logo {
        font-size: 1rem;
    }

    nav {
        gap: 0.5rem;
    }

    nav a {
        padding: 0.5rem;
        min-height: 44px;
        display: flex;
        align-items: center;
    }

    /* Sport selector - 3 columns on mobile */
    .sport-selector {
        grid-template-columns: repeat(3, 1fr);
        gap: 0.5rem;
    }

    .sport-pill {
        padding: 0.6rem 0.3rem;
        font-size: 0.7rem;
        min-height: 44px;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    /* Showcase panel - compact */
    .showcase-panel {
        padding: 1rem 1.5rem;
        min-height: auto;
    }

    .showcase-panel h1 {
        font-size: 1.4rem;
        line-height: 1.3;
    }

    .tagline {
        font-size: 0.9rem;
        margin-bottom: 1rem;
    }

    .before-after-container {
        gap: 0.75rem;
    }

    .ba-card {
        width: 120px;
        height: 165px;
    }

    .ba-label {
        font-size: 0.65rem;
        padding: 4px 10px;
    }

    .ba-arrow {
        font-size: 1.2rem;
    }

    .arrow-line {
        width: 25px;
    }

    .showcase-note {
        font-size: 0.8rem;
    }

    /* Create panel - optimized padding */
    .create-panel {
        padding: 1rem;
    }

    .create-card {
        padding: 1.25rem;
        border-radius: 16px;
    }

    .create-card h2 {
        font-size: 1.3rem;
        margin-bottom: 1rem;
    }

    /* Upload zone - touch optimized */
    .upload-zone {
        padding: 1.5rem 1rem;
        margin-bottom: 1rem;
    }

    .upload-icon {
        font-size: 2.5rem;
    }

    #file-name {
        font-size: 0.95rem;
    }

    .upload-hint {
        font-size: 0.8rem;
    }

    /* Generate button - touch friendly */
    .generate-btn {
        padding: 1rem;
        font-size: 1rem;
        min-height: 50px;
    }

    .create-note {
        font-size: 0.75rem;
    }

    /* Result state improvements */
    .result-content {
        grid-template-columns: 1fr;
    }

    .result-header h2 {
        font-size: 1.4rem;
    }

    .result-actions {
        width: 100%;
        justify-content: center;
    }

    .action-btn {
        flex: 1;
        justify-content: center;
        min-height: 44px;
    }

    .result-preview {
        max-width: 100%;
        border-radius: 12px;
    }

    /* Edit panel - mobile optimized */
    .edit-panel {
        padding: 1rem;
    }

    .edit-prompt-input {
        min-height: 50px;
        font-size: 16px;
        /* Prevents zoom on iOS */
    }

    .style-buttons {
        flex-direction: row;
    }

    .style-btn {
        flex: 1;
        min-height: 44px;
        font-size: 0.8rem;
    }

    .apply-edit-btn {
        min-height: 48px;
    }

    /* Iteration history */
    .history-thumbnail {
        width: 50px;
        height: 50px;
    }

    /* Pricing cards - smaller on mobile */
    .pricing-card {
        flex: 0 0 240px;
        min-width: 240px;
    }

    .format-title {
        font-size: 1rem;
    }

    .try-again-btn {
        min-height: 44px;
    }
}

/* === Small Mobile Breakpoint (480px) === */
@media (max-width: 480px) {

    /* Sport selector - 3 columns on small mobile */
    .sport-selector {
        grid-template-columns: repeat(3, 1fr);
        gap: 0.5rem;
    }

    .sport-pill {
        padding: 0.6rem 0.3rem;
        font-size: 0.7rem;
        min-height: 44px;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    /* Even smaller before/after cards */
    .ba-card {
        width: 110px;
        height: 150px;
    }

    .ba-label {
        font-size: 0.6rem;
        padding: 3px 8px;
        bottom: 8px;
    }

    /* Pricing cards - even narrower */
    .pricing-card {
        flex: 0 0 220px;
        min-width: 220px;
        padding: 1rem 0.75rem;
    }

    .price-current {
        font-size: 1.5rem;
    }

    .card-features {
        font-size: 0.65rem;
    }

    .resolution-select {
        font-size: 0.75rem;
        padding: 0.5rem;
    }
}

/* === Touch Device Improvements === */
@media (hover: none) and (pointer: coarse) {

    /* Disable hover transforms on touch devices */
    .pricing-card:hover,
    .ba-card:hover,
    .faq-item:hover {
        transform: none;
    }

    /* Better active states for touch */
    .generate-btn:active,
    .card-btn:active,
    .action-btn:active,
    .apply-edit-btn:active,
    .try-again-btn:active {
        transform: scale(0.98);
        opacity: 0.9;
    }
}

/* === Ensure inputs don't zoom on iOS === */
@media (max-width: 600px) {

    input,
    select,
    textarea {
        font-size: 16px;
    }
}

/* ===== FAQ SECTION ===== */
.faq-section {
    padding: 80px 40px;
    background: linear-gradient(180deg, var(--background) 0%, rgba(10, 15, 30, 1) 100%);
}

.faq-container {
    max-width: 800px;
    margin: 0 auto;
}

.faq-title {
    font-size: 2.5rem;
    font-weight: 800;
    text-align: center;
    margin-bottom: 3rem;
    color: var(--text);
}

.faq-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.faq-item {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 16px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.faq-item:hover {
    border-color: var(--primary);
    box-shadow: 0 4px 20px rgba(255, 107, 0, 0.1);
}

.faq-question {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 28px;
    background: transparent;
    border: none;
    color: var(--text);
    font-size: 1.1rem;
    font-weight: 600;
    font-family: inherit;
    text-align: left;
    cursor: pointer;
    transition: all 0.3s ease;
}

.faq-question:hover {
    color: var(--primary);
}

.faq-icon {
    font-size: 1.5rem;
    font-weight: 300;
    color: var(--primary);
    transition: transform 0.3s ease;
    flex-shrink: 0;
    margin-left: 16px;
}

.faq-item.active .faq-icon {
    transform: rotate(45deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, padding 0.4s ease;
}

.faq-item.active .faq-answer {
    max-height: 500px;
}

.faq-answer p {
    padding: 0 28px 16px 28px;
    color: var(--text-dim);
    font-size: 1rem;
    line-height: 1.7;
    margin: 0;
}

.faq-answer p:last-child {
    padding-bottom: 24px;
}

.faq-signature {
    font-style: italic;
    color: var(--primary) !important;
    font-weight: 600;
    padding-top: 8px !important;
}

.faq-link {
    color: var(--primary);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}

.faq-link:hover {
    color: var(--accent);
    text-decoration: underline;
}

/* FAQ Responsive */
@media (max-width: 768px) {
    .faq-section {
        padding: 60px 20px;
    }

    .faq-title {
        font-size: 2rem;
    }

    .faq-question {
        padding: 20px;
        font-size: 1rem;
    }

    .faq-answer p {
        padding: 0 20px 20px 20px;
        font-size: 0.95rem;
    }
}
.logo-header-img {
    height: 40px;
    width: auto;
}
