/* =====================================
   Football Profile - Main Styles
   ===================================== */

:root {
    --bg-primary: #0a0a12;
    --bg-secondary: #12121a;
    --bg-card: #1a1a26;
    --bg-surface: #22222e;
    --bg-input: #2a2a38;
    
    --text-primary: #ffffff;
    --text-secondary: #a0a0b0;
    --text-muted: #6a6a7a;
    
    --accent-primary: #f5c842;
    --accent-secondary: #e63946;
    --accent-gradient: linear-gradient(135deg, #f5c842 0%, #e63946 100%);
    --accent-glow: rgba(245, 200, 66, 0.3);
    
    --green-gold: #7cb342;
    --pitch-green: #2d5a3d;
    
    --border-color: #2a2a38;
    --border-light: #3a3a48;
    
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 8px 40px rgba(0, 0, 0, 0.5);
    --shadow-glow: 0 0 30px var(--accent-glow);
    
    --radius-sm: 6px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --radius-xl: 28px;
}

/* Theme: Classic */
.theme-classic { --card-bg: linear-gradient(145deg, #1e1e2a 0%, #16161f 100%); --card-accent: #f5c842; --card-text: #ffffff; --card-border: rgba(245, 200, 66, 0.2); --card-glow: rgba(245, 200, 66, 0.15); }

/* Theme: Dark */
.theme-dark { --card-bg: linear-gradient(180deg, #0d0d14 0%, #1a1a2e 100%); --card-accent: #7c3aed; --card-text: #e0e0f0; --card-border: rgba(124, 58, 237, 0.3); --card-glow: rgba(124, 58, 237, 0.2); }

/* Theme: Stadium */
.theme-stadium { --card-bg: linear-gradient(180deg, #1a3a25 0%, #0d2616 100%); --card-accent: #7cb342; --card-text: #ffffff; --card-border: rgba(124, 179, 66, 0.3); --card-glow: rgba(124, 179, 66, 0.2); }

/* Theme: Neon */
.theme-neon { --card-bg: linear-gradient(135deg, #0a0a12 0%, #1a0a2e 100%); --card-accent: #00ff88; --card-text: #ffffff; --card-border: rgba(0, 255, 136, 0.4); --card-glow: rgba(0, 255, 136, 0.3); }

/* Theme: Minimal */
.theme-minimal { --card-bg: #ffffff; --card-accent: #1a1a1a; --card-text: #1a1a1a; --card-border: #e0e0e0; --card-glow: rgba(0, 0, 0, 0.05); }

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
    font-family: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
}

.page { display: none; min-height: 100vh; }
.page.active { display: block; }

.landing-container {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
}

.landing-container::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 80%;
    height: 100%;
    background: radial-gradient(circle, var(--accent-glow) 0%, transparent 60%);
    pointer-events: none;
    z-index: 0;
}

.landing-container::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 200px;
    background: linear-gradient(180deg, transparent 0%, var(--bg-primary) 100%);
    pointer-events: none;
    z-index: 0;
}

.landing-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    padding: 20px 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(180deg, rgba(10, 10, 18, 0.95) 0%, transparent 100%);
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 700;
    font-size: 20px;
    color: var(--text-primary);
}

.logo-icon {
    width: 36px;
    height: 36px;
    color: var(--accent-primary);
}

.badge {
    display: inline-block;
    padding: 6px 16px;
    background: var(--accent-gradient);
    color: #0a0a12;
    font-weight: 600;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-radius: 100px;
    margin-bottom: 24px;
}

.hero-section {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 120px 40px 80px;
    gap: 60px;
    position: relative;
    z-index: 1;
}

.hero-content {
    flex: 1;
    max-width: 600px;
    text-align: left;
}

.hero-content h1 {
    font-family: 'Space Grotesk', sans-serif;
    font-size: clamp(48px, 8vw, 88px);
    font-weight: 900;
    line-height: 1.05;
    margin-bottom: 24px;
    letter-spacing: -2px;
}

.gradient-text {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.subtitle {
    font-size: 20px;
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 40px;
    max-width: 480px;
}

.cta-button {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 16px 32px;
    background: var(--accent-gradient);
    color: #0a0a12;
    font-weight: 700;
    font-size: 16px;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-glow);
}

.cta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 40px var(--accent-glow);
}

.cta-button .arrow-icon {
    width: 20px;
    height: 20px;
    transition: transform 0.3s ease;
}

.cta-button:hover .arrow-icon {
    transform: translateX(4px);
}

.hero-visual {
    flex: 0 0 400px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.example-card-wrapper { perspective: 1000px; }

.example-card {
    width: 320px;
    background: var(--card-bg);
    border-radius: var(--radius-lg);
    border: 1px solid var(--card-border);
    padding: 32px;
    box-shadow: var(--shadow-lg), 0 0 60px var(--card-glow);
    position: relative;
    overflow: hidden;
}

.example-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--accent-gradient);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
}

.card-badge {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--accent-primary);
}

.card-theme-indicator {
    width: 60px;
    height: 4px;
    background: var(--accent-gradient);
    border-radius: 2px;
}

.card-profile-image {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    background: var(--bg-surface);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    border: 3px solid var(--card-accent);
}

.placeholder-avatar {
    width: 70%;
    height: 70%;
    color: var(--text-muted);
}

.card-name {
    text-align: center;
    font-size: 28px;
    font-weight: 800;
    margin-bottom: 4px;
    letter-spacing: -0.5px;
}

.card-social {
    text-align: center;
    font-size: 14px;
    color: var(--accent-primary);
    font-weight: 500;
    margin-bottom: 20px;
}

.card-divider {
    height: 1px;
    background: var(--border-color);
    margin: 0 auto 20px;
    width: 80%;
}

.card-section {
    margin-bottom: 16px;
}

.card-label {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--text-muted);
    margin-bottom: 4px;
    text-align: center;
}

.card-value {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
    text-align: center;
}

.club-crest {
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-surface);
    border-radius: 50%;
    margin: 8px auto 0;
    color: var(--accent-primary);
}

.placeholder-crest svg {
    width: 70%;
    height: 70%;
}

.card-footer {
    display: flex;
    justify-content: space-between;
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}

.card-stat {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: var(--text-secondary);
}

.card-stat svg {
    width: 16px;
    height: 16px;
    color: var(--accent-primary);
}

.match-display {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 8px;
    justify-content: center;
}

.match-team {
    flex: 1;
    text-align: center;
    font-weight: 600;
    font-size: 14px;
    padding: 8px 12px;
    background: var(--bg-surface);
    border-radius: var(--radius-sm);
}

.match-score {
    font-size: 18px;
    font-weight: 700;
    color: var(--accent-primary);
    padding: 0 8px;
}

.goal-display { margin-top: 8px; text-align: center; }

.goal-scorer {
    font-weight: 700;
    color: var(--accent-primary);
    font-size: 14px;
}

.goal-teams {
    font-size: 13px;
    color: var(--text-secondary);
    margin-top: 2px;
}

.goal-teams .vs { color: var(--text-muted); margin: 0 4px; }

.goal-score {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-primary);
    margin-top: 4px;
}

.landing-footer {
    padding: 24px 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    position: relative;
    z-index: 1;
}

.landing-footer p { font-size: 12px; color: var(--text-muted); }

.footer-links { display: flex; gap: 24px; }

.footer-link {
    font-size: 12px;
    color: var(--text-secondary);
    cursor: pointer;
    transition: color 0.2s;
}

.footer-link:hover { color: var(--accent-primary); }

.builder-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 32px;
    background: rgba(10, 10, 18, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
}

.nav-back {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: var(--bg-surface);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-weight: 500;
    font-size: 14px;
    transition: all 0.2s;
}

.nav-back:hover { background: var(--bg-input); border-color: var(--accent-primary); }
.nav-back svg { width: 18px; height: 18px; }

.nav-logo { font-family: 'Space Grotesk', sans-serif; font-weight: 700; font-size: 18px; color: var(--accent-primary); }

.reset-button {
    padding: 8px 16px;
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s;
}

.reset-button:hover { color: var(--accent-secondary); border-color: var(--accent-secondary); }

.builder-main {
    margin-top: 80px;
    padding: 32px;
    min-height: calc(100vh - 80px);
}

.builder-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    max-width: 1400px;
    margin: 0 auto;
}

.editor-section { display: flex; flex-direction: column; gap: 32px; }

.editor-header { margin-bottom: 8px; }

.editor-header h1 {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 32px;
    font-weight: 800;
    margin-bottom: 8px;
    letter-spacing: -1px;
}

.editor-header p { color: var(--text-secondary); font-size: 16px; }

.theme-selector {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px;
}

.theme-label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-muted);
    margin-bottom: 12px;
}

.theme-buttons { display: flex; flex-wrap: wrap; gap: 8px; }

.theme-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    transition: all 0.2s;
}

.theme-btn:hover { border-color: var(--border-light); color: var(--text-primary); }

.theme-btn.active {
    background: var(--accent-gradient);
    border-color: transparent;
    color: #0a0a12;
    font-weight: 600;
}

.theme-btn.active .theme-dot { box-shadow: 0 0 8px currentColor; }

.theme-dot { width: 12px; height: 12px; border-radius: 50%; }
.classic-dot { background: var(--accent-primary); }
.dark-dot { background: #7c3aed; }
.stadium-dot { background: #7cb342; }
.neon-dot { background: #00ff88; }
.minimal-dot { background: #1a1a1a; }

.editor-content { display: flex; flex-direction: column; gap: 32px; }

.form-section {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 24px;
}

.section-title {
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--accent-primary);
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border-color);
}

.form-group { margin-bottom: 16px; }
.form-group:last-child { margin-bottom: 0; }

.form-group label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 6px;
}

.form-group label .required { color: var(--accent-secondary); margin-left: 4px; }

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 14px;
    font-family: inherit;
    transition: all 0.2s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px var(--accent-glow);
}

.form-group input::placeholder,
.form-group textarea::placeholder { color: var(--text-muted); }

.form-group select {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%236a6a7a' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 40px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.char-count {
    display: block;
    margin-top: 4px;
    font-size: 11px;
    color: var(--text-muted);
    text-align: right;
}

.char-count.warning { color: #ffa726; }
.char-count.danger { color: var(--accent-secondary); }

.photo-upload { position: relative; }

.photo-upload input[type="file"] {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

.photo-preview {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 24px;
    background: var(--bg-input);
    border: 2px dashed var(--border-color);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all 0.2s;
}

.photo-preview:hover { border-color: var(--accent-primary); background: var(--bg-surface); }

.upload-icon { width: 32px; height: 32px; color: var(--text-muted); }

.photo-preview span { font-size: 13px; color: var(--text-secondary); }

.input-prefix { position: relative; }

.input-prefix .prefix {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-weight: 500;
}

.input-prefix input { padding-left: 32px; }

.preview-section {
    position: sticky;
    top: 100px;
    height: fit-content;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.preview-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.preview-header h2 { font-family: 'Space Grotesk', sans-serif; font-size: 20px; font-weight: 700; }

.preview-status {
    font-size: 12px;
    color: var(--green-gold);
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 6px;
}

.preview-status::before {
    content: '';
    width: 6px;
    height: 6px;
    background: var(--green-gold);
    border-radius: 50%;
}

.preview-card-container {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding: 20px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    min-height: 500px;
}

.profile-card {
    width: 100%;
    max-width: 380px;
    background: var(--card-bg);
    border-radius: var(--radius-xl);
    border: 2px solid var(--card-border);
    padding: 28px 24px 24px;
    box-shadow: var(--shadow-lg), 0 0 40px var(--card-glow);
    position: relative;
    overflow: hidden;
}

.profile-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--card-accent);
}

.card-wrapper { position: relative; }

.card-header-section {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 20px;
}

.card-theme-badge {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--card-accent);
    background: rgba(255, 255, 255, 0.05);
    padding: 4px 10px;
    border-radius: 100px;
    border: 1px solid var(--card-border);
}

.card-design-elements {
    position: absolute;
    top: -20px;
    right: -10px;
    width: 100px;
    height: 100px;
    background: radial-gradient(circle, var(--card-glow) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

.card-photo-section { display: flex; justify-content: center; margin-bottom: 16px; }

.profile-image-container {
    width: 90px;
    height: 90px;
    border-radius: 50%;
    overflow: hidden;
    border: 4px solid var(--card-accent);
    background: var(--bg-surface);
}

.profile-image { width: 100%; height: 100%; object-fit: cover; }

.photo-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.photo-placeholder svg { width: 60%; height: 60%; color: var(--text-muted); }

.card-identity-section { text-align: center; margin-bottom: 16px; }

.card-display-name {
    font-size: 26px;
    font-weight: 800;
    color: var(--card-text);
    letter-spacing: -0.5px;
    line-height: 1.2;
}

.card-social-handle {
    font-size: 14px;
    color: var(--card-accent);
    font-weight: 500;
    margin-top: 4px;
}

.card-content-section {
    padding: 14px 0;
    border-top: 1px solid var(--card-border);
}

.card-label {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--text-muted);
    margin-bottom: 4px;
}

.card-club-row { display: flex; align-items: center; gap: 12px; }

.card-club-value {
    flex: 1;
    font-size: 18px;
    font-weight: 700;
    color: var(--card-text);
}

.club-crest-large {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 50%;
    border: 2px solid var(--card-border);
}

.crest-placeholder svg { width: 70%; height: 70%; color: var(--card-accent); }

.card-player-row { display: flex; align-items: center; gap: 12px; margin-top: 4px; }

.card-player-number {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--card-accent);
    color: #0a0a12;
    font-weight: 800;
    font-size: 16px;
    border-radius: 50%;
}

.card-player-value { font-size: 18px; font-weight: 700; color: var(--card-text); }

.card-goat-row { display: flex; align-items: center; gap: 10px; margin-top: 4px; }

.goat-badge {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--card-accent);
    background: rgba(255, 255, 255, 0.08);
    padding: 4px 8px;
    border-radius: 4px;
    border: 1px solid var(--card-accent);
}

.card-goat-value { font-size: 18px; font-weight: 700; color: var(--card-text); }

.card-side-section {
    display: flex;
    gap: 12px;
    padding: 12px 0;
    border-top: 1px solid var(--card-border);
}

.secondary-player-item {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: var(--radius-sm);
}

.secondary-label { font-size: 10px; font-weight: 700; color: var(--text-muted); }
.secondary-value { font-size: 14px; font-weight: 600; color: var(--card-text); }

.card-match-section {
    margin-top: 16px;
    padding: 16px 0;
    border-top: 1px solid var(--card-border);
}

.match-header { margin-bottom: 12px; }

.match-label {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--text-muted);
}

.match-display-section {
    display: flex;
    align-items: center;
    gap: 8px;
}

.match-team-block { display: flex; align-items: center; gap: 8px; flex: 1; }

.team-crest-placeholder {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 50%;
    border: 1px solid var(--card-border);
}

.team-crest-placeholder svg { width: 60%; height: 60%; color: var(--card-accent); }

.team-name {
    font-size: 13px;
    font-weight: 600;
    color: var(--card-text);
    text-align: center;
    padding: 4px 8px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: var(--radius-sm);
}

.match-score-block {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    padding: 0 12px;
}

.match-score-value { font-size: 18px; font-weight: 800; color: var(--card-accent); }

.match-scores-separator {
    width: 16px;
    height: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
}

.match-scores-separator svg { width: 100%; height: 100%; }

.match-competition {
    font-size: 11px;
    color: var(--card-accent);
    text-align: center;
    margin-top: 10px;
    font-weight: 600;
}

.card-goal-section {
    margin-top: 16px;
    padding: 16px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: var(--radius-md);
    border: 1px solid var(--card-border);
}

.goal-banner { display: flex; justify-content: center; margin-bottom: 12px; }

.goal-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    background: var(--card-accent);
    color: #0a0a12;
    padding: 4px 12px;
    border-radius: 100px;
}

.goal-content { text-align: center; }

.goal-header-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-bottom: 8px;
}

.goal-scorer-block { display: flex; align-items: center; gap: 8px; }

.scorer-avatar-placeholder {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 50%;
    border: 1px solid var(--card-border);
}

.scorer-avatar-placeholder svg { width: 60%; height: 60%; color: var(--card-accent); }

.goal-scorer-name { font-size: 15px; font-weight: 700; color: var(--card-text); }

.goal-score-block {
    padding: 6px 12px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: var(--radius-sm);
    border: 1px solid var(--card-border);
}

.goal-match-score { font-size: 16px; font-weight: 700; color: var(--card-accent); }

.goal-teams-row {
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.goal-teams-row .goal-team { font-weight: 500; }
.goal-teams-row .goal-vs { color: var(--text-muted); margin: 0 6px; }

.goal-meta-row {
    display: flex;
    justify-content: center;
    gap: 16px;
    font-size: 11px;
    color: var(--text-muted);
    margin-bottom: 10px;
}

.goal-meta-row span {
    padding: 2px 8px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 4px;
}

.goal-description {
    font-size: 13px;
    color: var(--card-text);
    font-style: italic;
    line-height: 1.4;
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: var(--radius-sm);
    margin-bottom: 8px;
}

.goal-why { font-size: 12px; color: var(--card-accent); }
.why-label { font-weight: 600; margin-right: 4px; }

.card-identity-section {
    margin-top: 16px;
    padding: 14px 0;
    border-top: 1px solid var(--card-border);
}

.identity-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
}

.identity-item {
    text-align: center;
    padding: 8px 4px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: var(--radius-sm);
}

.identity-label {
    display: block;
    font-size: 9px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-muted);
    margin-bottom: 2px;
}

.identity-value {
    font-size: 13px;
    font-weight: 600;
    color: var(--card-text);
}

.identity-value.shirt-value {
    color: var(--card-accent);
    font-size: 16px;
}

.card-preferences-section {
    margin-top: 12px;
    padding: 12px 0;
    border-top: 1px solid var(--card-border);
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.preference-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 10px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: var(--radius-sm);
}

.pref-label { font-size: 11px; color: var(--text-muted); font-weight: 500; }
.pref-value { font-size: 12px; font-weight: 600; color: var(--card-text); }

.card-bio-section {
    margin-top: 12px;
    padding: 12px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: var(--radius-sm);
}

.bio-label {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--text-muted);
    margin-bottom: 6px;
}

.bio-text { font-size: 13px; color: var(--card-text); line-height: 1.4; }

.card-footer-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid var(--card-border);
}

.card-brand { display: flex; align-items: center; gap: 8px; }

.card-logo { width: 24px; height: 24px; color: var(--card-accent); }

.brand-text {
    font-size: 11px;
    font-weight: 600;
    color: var(--text-muted);
    letter-spacing: 0.5px;
}

.card-footer-stats { display: flex; gap: 12px; }

.footer-stat {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    color: var(--text-muted);
}

.footer-stat svg { width: 14px; height: 14px; color: var(--card-accent); }

.toast {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    padding: 12px 24px;
    background: var(--bg-surface);
    color: var(--text-primary);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-sm);
    font-size: 14px;
    font-weight: 500;
    z-index: 1000;
    opacity: 0;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-lg);
}

.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
.toast.success { border-color: var(--green-gold); }

@media (max-width: 1024px) {
    .builder-main { padding: 24px; }
    .builder-container { grid-template-columns: 1fr; gap: 32px; }
    .preview-section { position: static; }
    .preview-card-container { min-height: auto; }
    .profile-card { max-width: 340px; }
}

@media (max-width: 768px) {
    .landing-nav { padding: 16px 20px; }
    .landing-footer {
        padding: 16px 20px;
        flex-direction: column;
        gap: 12px;
        text-align: center;
    }
    .hero-section {
        flex-direction: column;
        padding: 100px 20px 60px;
        gap: 40px;
        text-align: center;
    }
    .hero-content { max-width: 100%; text-align: center; }
    .hero-content h1 { font-size: 48px; }
    .subtitle { margin-left: auto; margin-right: auto; }
    .badge { display: inline-block; }
    .cta-button { width: 100%; justify-content: center; }
    .hero-visual { flex: 0 0 auto; width: 100%; max-width: 320px; }
    .example-card { width: 100%; }
    .builder-nav { padding: 12px 16px; }
    .nav-logo { font-size: 16px; }
    .nav-back span { display: none; }
    .builder-main { margin-top: 64px; padding: 16px; }
    .form-row { grid-template-columns: 1fr; }
    .identity-row { grid-template-columns: repeat(2, 1fr); }
    .profile-card { padding: 20px 16px; }
}

@media (max-width: 480px) {
    .preview-card-container { padding: 12px; border-radius: var(--radius-md); }
    .profile-card { max-width: 100%; border-radius: var(--radius-lg); }
    .card-display-name { font-size: 22px; }
    .identity-row { grid-template-columns: repeat(2, 1fr); gap: 4px; }
    .match-display-section { flex-direction: column; gap: 6px; }
    .match-score-block { flex-direction: row; padding: 4px 0; }
}

/* =====================================
   Search Components Styles
   ===================================== */

.search-container {
    position: relative;
}

.search-input-wrapper {
    position: relative;
}

.search-input-wrapper .search-icon {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    pointer-events: none;
}

.search-input-wrapper input {
    padding-right: 40px;
}

.search-input-wrapper .search-trigger {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    padding: 4px 8px;
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 12px;
    transition: all 0.2s;
    z-index: 2;
}

.search-input-wrapper .search-trigger:hover {
    background: var(--bg-input);
    border-color: var(--accent-primary);
    color: var(--text-primary);
}

.search-results {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin-top: 4px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    max-height: 320px;
    overflow-y: auto;
    z-index: 100;
    display: none;
}

.search-results.active {
    display: block;
}

.search-results .search-result-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    cursor: pointer;
    transition: background 0.15s;
    border-bottom: 1px solid var(--border-color);
}

.search-results .search-result-item:last-child {
    border-bottom: none;
}

.search-results .search-result-item:hover,
.search-results .search-result-item.selected {
    background: var(--bg-surface);
}

.search-results .search-result-item .result-image-container {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    overflow: hidden;
    background: var(--bg-input);
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.search-results .search-result-item .result-image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.search-results .search-result-item .result-image-container .fallback-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.search-results .search-result-item .result-image-container .fallback-placeholder svg {
    width: 60%;
    height: 60%;
    color: var(--text-muted);
}

.search-results .search-result-item .result-image-container.league-logo {
    border-radius: var(--radius-sm);
}

.search-results .search-result-item .result-info {
    flex: 1;
    min-width: 0;
}

.search-results .search-result-item .result-name {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.search-results .search-result-item .result-meta {
    display: flex;
    gap: 8px;
    margin-top: 2px;
    font-size: 12px;
    color: var(--text-muted);
}

.search-results .search-result-item .result-meta span {
    display: flex;
    align-items: center;
}

.search-results .search-result-item .result-meta .result-team::before {
    content: '';
    width: 6px;
    height: 6px;
    background: var(--accent-primary);
    border-radius: 50%;
    margin-right: 4px;
}

.search-results .search-result-item .result-meta .result-nationality::before {
    content: '';
    width: 6px;
    height: 6px;
    background: var(--pitch-green);
    border-radius: 50%;
    margin-right: 4px;
}

.search-results .search-result-item .result-meta .result-country::before {
    content: '';
    width: 6px;
    height: 6px;
    background: var(--accent-secondary);
    border-radius: 50%;
    margin-right: 4px;
}

.search-results .search-result-item .result-meta .result-league::before {
    content: '';
    width: 6px;
    height: 6px;
    background: var(--green-gold);
    border-radius: 50%;
    margin-right: 4px;
}

.search-results .no-results,
.search-results .search-loading,
.search-results .search-error {
    padding: 16px;
    text-align: center;
    font-size: 13px;
    color: var(--text-muted);
}

.search-results .search-loading {
    color: var(--accent-primary);
}

.search-results .search-error {
    color: var(--accent-secondary);
}

/* Entity inputs with stored data indicator */
.entity-input-wrapper {
    position: relative;
}

.entity-input-wrapper .entity-badge {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    display: none;
    align-items: center;
    gap: 4px;
    padding: 4px 8px;
    background: var(--accent-gradient);
    color: #0a0a12;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-radius: 100px;
}

.entity-input-wrapper.has-entity .entity-badge {
    display: flex;
}

.entity-input-wrapper .entity-badge svg {
    width: 10px;
    height: 10px;
}

/* Profile card entity images */
.card-entity-image {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    overflow: hidden;
    background: var(--bg-surface);
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--card-border);
}

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

.card-entity-image .entity-fallback {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.card-entity-image .entity-fallback svg {
    width: 60%;
    height: 60%;
    color: var(--card-accent);
}

.card-entity-image.team-crest {
    border-radius: 50%;
}

.card-entity-logo {
    width: 28px;
    height: 28px;
    border-radius: var(--radius-sm);
    overflow: hidden;
    background: var(--bg-surface);
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--card-border);
}

.card-entity-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.card-entity-logo .entity-fallback {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.card-entity-logo .entity-fallback svg {
    width: 60%;
    height: 60%;
    color: var(--card-accent);
}
