
@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@400;600;700;900&family=Cinzel+Decorative:wght@400;700;900&family=Cormorant+Garamond:wght@300;400;500;600;700&display=swap');

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

:root {

    --dark-primary: #0a0a0f;
    --dark-secondary: #12121a;
    --dark-tertiary: #1a1a28;
    
    --gold: #c9a227;
    --gold-light: #f4d03f;
    --gold-dark: #9d7b1e;
    
    --blood-red: #8b0000;
    --blood-red-light: #b91c1c;
    --blood-red-dark: #5c0000;
    
    --ice-blue: #a5c9ff;
    --ice-blue-dark: #4a7fb8;
    

    --light: #f8fafc;
    --gray-light: #cbd5e1;
    --gray: #94a3b8;
    --gray-dark: #475569;
    
  
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.5);
    --shadow-lg: 0 16px 48px rgba(0, 0, 0, 0.7);
    --shadow-xl: 0 24px 64px rgba(0, 0, 0, 0.8);
    

    --transition-fast: 0.2s ease;
    --transition-normal: 0.4s ease;
    --transition-slow: 0.6s ease;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: "Cormorant Garamond", serif;
    background: var(--dark-primary);
    color: var(--light);
    line-height: 1.8;
    overflow-x: hidden;
    position: relative;
}

body::before {
    content: '';
    position: fixed;
    inset: 0;
    background: 
        radial-gradient(ellipse at top, rgba(201, 162, 39, 0.03), transparent 50%),
        radial-gradient(ellipse at bottom, rgba(139, 0, 0, 0.05), transparent 50%);
    pointer-events: none;
    z-index: 0;
}

h1, h2, h3, h4, h5, h6 {
    font-family: "Cinzel", serif;
    font-weight: 700;
    letter-spacing: 0.05em;
    line-height: 1.2;
}


a {
    color: inherit;
    text-decoration: none;
    transition: var(--transition-normal);
}

.container {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
    position: relative;
    z-index: 1;
}

.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(10, 10, 15, 0.8);
    backdrop-filter: blur(20px) saturate(180%);
    border-bottom: 1px solid rgba(201, 162, 39, 0.1);
    padding: 1.25rem 0;
    z-index: 999;
    transition: var(--transition-normal);
}

.header.scrolled {
    padding: 0.75rem 0;
    box-shadow: var(--shadow-lg);
    border-bottom-color: rgba(201, 162, 39, 0.2);
}

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

.logo {
    font-family: "Cinzel Decorative", serif;
    font-size: 1.5rem;
    font-weight: 900;
    background: linear-gradient(135deg, var(--gold), var(--gold-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 0 30px rgba(201, 162, 39, 0.3);
    letter-spacing: 0.1em;
    position: relative;
}

.logo::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--gold), transparent);
    opacity: 0.5;
}

.nav-list {
    list-style: none;
    display: flex;
    gap: 3rem;
    align-items: center;
}

.nav-list li {
    position: relative;
}

.nav-list a {
    font-family: "Cinzel", serif;
    font-size: 0.95rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--gray-light);
    padding: 0.5rem 0;
    position: relative;
    transition: var(--transition-normal);
}

.nav-list a::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--gold-dark), var(--gold), var(--gold-dark));
    transform: translateX(-50%);
    transition: width var(--transition-normal);
}

.nav-list a:hover {
    color: var(--gold-light);
    text-shadow: 0 0 20px rgba(201, 162, 39, 0.5);
}

.nav-list a:hover::before {
    width: 100%;
}

.menu-toggle {
    display: none;
    background: none;
    border: 2px solid var(--gold);
    color: var(--gold);
    font-size: 1.5rem;
    padding: 0.5rem 1rem;
    cursor: pointer;
    border-radius: 4px;
    transition: var(--transition-normal);
}

.menu-toggle:hover {
    background: var(--gold);
    color: var(--dark-primary);
    box-shadow: 0 0 20px rgba(201, 162, 39, 0.4);
}

.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
    overflow: hidden;
    background: linear-gradient(to bottom, rgba(10, 10, 15, 0.1), rgba(10, 10, 10, 0.55)),
                url(../assets/image/iron-throne.PNG);
    background-size: 600px;
    background-position: center top;
    background-repeat: no-repeat;
    margin-top: 60px;
}

.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: 
        radial-gradient(ellipse at center, transparent 0%, rgba(0, 0, 0, 0.8) 100%),
        linear-gradient(to bottom, rgba(139, 0, 0, 0.1) 0%, transparent 40%, transparent 60%, rgba(10, 10, 15, 0.9) 100%);
    pointer-events: none;
}

.hero-atmosphere {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 20% 30%, rgba(201, 162, 39, 0.03), transparent 40%),
        radial-gradient(circle at 80% 70%, rgba(139, 0, 0, 0.05), transparent 40%);
    animation: atmosphereFloat 20s ease-in-out infinite;
    pointer-events: none;
}

@keyframes atmosphereFloat {
    0%, 100% {
        transform: scale(1) rotate(0deg);
        opacity: 0.6;
    }
    50% {
        transform: scale(1.1) rotate(5deg);
        opacity: 0.8;
    }
}

.hero-content {
    max-width: 900px;
    padding: 2rem;
    position: relative;
    z-index: 2;
    animation: heroFadeIn 1.5s ease-out;
}

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

.hero h2 {
    font-family: "Cinzel Decorative", serif;
    font-size: clamp(3rem, 8vw, 5rem);
    font-weight: 900;
    margin-bottom: 1.5rem;
    background: linear-gradient(135deg, var(--light), var(--gold-light), var(--light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 10px 40px rgba(201, 162, 39, 0.3);
    letter-spacing: 0.15em;
    line-height: 1.1;
    animation: titleGlow 3s ease-in-out infinite;
    position: relative;
}

@keyframes titleGlow {
    0%, 100% {
        filter: drop-shadow(0 0 20px rgba(201, 162, 39, 0.4));
    }
    50% {
        filter: drop-shadow(0 0 40px rgba(201, 162, 39, 0.6));
    }
}

.hero p {
    color: var(--gray-light);
    font-size: 1.4rem;
    max-width: 600px;
    margin: 0 auto 3rem;
    font-weight: 300;
    letter-spacing: 0.05em;
    line-height: 1.8;
}

.btn-primary {
    display: inline-block;
    font-family: "Cinzel", serif;
    font-weight: 700;
    font-size: 1.1rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    padding: 1.2rem 3rem;
    background: linear-gradient(135deg, var(--blood-red), var(--blood-red-light));
    color: var(--light);
    border: 2px solid rgba(201, 162, 39, 0.3);
    border-radius: 4px;
    position: relative;
    overflow: hidden;
    cursor: pointer;
    transition: all var(--transition-normal);
    box-shadow: 
        0 8px 24px rgba(139, 0, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.6s ease;
}

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

.btn-primary:hover {
    transform: translateY(-4px) scale(1.02);
    box-shadow: 
        0 16px 40px rgba(139, 0, 0, 0.6),
        0 0 40px rgba(201, 162, 39, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    border-color: var(--gold);
}

.btn-primary:active {
    transform: translateY(-2px) scale(1);
}

.section-title {
    font-family: "Cinzel Decorative", serif;
    text-align: center;
    font-size: clamp(2.5rem, 5vw, 3.5rem);
    font-weight: 900;
    margin-bottom: 4rem;
    background: linear-gradient(135deg, var(--gold-dark), var(--gold-light), var(--gold-dark));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: 0.1em;
    position: relative;
    padding-bottom: 2rem;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 150px;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--gold), transparent);
    border-radius: 2px;
}

.houses {
    padding: 8rem 0;
    position: relative;
}

.houses::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80%;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(201, 162, 39, 0.3), transparent);
}

.filters {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    justify-content: center;
    margin-bottom: 4rem;
}

.filters button {
    font-family: "Cinzel", serif;
    font-weight: 600;
    font-size: 0.9rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    padding: 0.8rem 1.8rem;
    border: 2px solid rgba(201, 162, 39, 0.2);
    border-radius: 30px;
    background: rgba(26, 26, 40, 0.6);
    backdrop-filter: blur(10px);
    color: var(--gray-light);
    cursor: pointer;
    transition: all var(--transition-normal);
    position: relative;
    overflow: hidden;
}

.filters button::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, var(--gold-dark), var(--gold));
    opacity: 0;
    transition: opacity var(--transition-normal);
}

.filters button span {
    position: relative;
    z-index: 1;
}

.filters button:hover {
    border-color: var(--gold);
    color: var(--light);
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(201, 162, 39, 0.3);
}

.filters button.active {
    background: linear-gradient(135deg, var(--gold-dark), var(--gold));
    border-color: var(--gold-light);
    color: var(--dark-primary);
    box-shadow: 
        0 8px 24px rgba(201, 162, 39, 0.5),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.filters button.active::before {
    opacity: 1;
}

.houses-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2.5rem;
    margin-top: 3rem;
}

.house-card {
    background: linear-gradient(145deg, rgba(26, 26, 40, 0.9), rgba(18, 18, 26, 0.95));
    border: 1px solid rgba(201, 162, 39, 0.15);
    border-radius: 16px;
    overflow: hidden;
    cursor: pointer;
    transition: all var(--transition-slow);
    position: relative;
    display: flex;
    flex-direction: column;
    min-height: 380px;
    backdrop-filter: blur(10px);
}

.house-card-inactive {
    opacity: 0.2 !important;
    filter: blur(2px);
    transition: all 0.5s ease;
    pointer-events: none;
}

.house-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(201, 162, 39, 0.05), transparent 60%);
    opacity: 0;
    transition: opacity var(--transition-slow);
    pointer-events: none;
}

.house-card:hover::before {
    opacity: 1;
}

.house-card::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(201, 162, 39, 0.1) 0%, transparent 70%);
    opacity: 0;
    transition: opacity var(--transition-slow);
    pointer-events: none;
}

.house-card:hover::after {
    opacity: 1;
}

.house-card:hover {
    transform: translateY(-12px) scale(1.02);
    border-color: var(--gold);
    box-shadow: 
        0 24px 60px rgba(0, 0, 0, 0.6),
        0 0 40px rgba(201, 162, 39, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.house-card img {
    width: 100%;
    height: 220px;
    object-fit: contain;
    background: linear-gradient(to bottom, rgba(10, 10, 15, 0.8), rgba(18, 18, 26, 0.9));
    padding: 2rem;
    transition: all var(--transition-slow);
    filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.5));
}

.house-card:hover img {
    transform: scale(1.1) translateY(-5px);
    filter: drop-shadow(0 8px 24px rgba(201, 162, 39, 0.4));
}

.house-content {
    padding: 2rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    flex: 1;
    position: relative;
    z-index: 1;
}

.house-content h2 {
    font-family: "Cinzel", serif;
    font-size: 1.6rem;
    font-weight: 700;
    margin-bottom: 0.8rem;
    color: var(--light);
    letter-spacing: 0.05em;
    transition: color var(--transition-normal);
}

.house-card:hover .house-content h2 {
    color: var(--gold-light);
    text-shadow: 0 0 20px rgba(201, 162, 39, 0.4);
}

.house-content p {
    color: var(--gray);
    font-style: italic;
    font-size: 1.1rem;
    margin-top: 0.5rem;
    line-height: 1.6;
    transition: color var(--transition-normal);
}

.house-card:hover .house-content p {
    color: var(--gray-light);
}

.house-card.hidden {
    opacity: 0;
    transform: scale(0.9);
    pointer-events: none;
}

.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(15px) saturate(120%);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: all var(--transition-slow);
    z-index: 2000;
    padding: 2rem;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.modal-content {
    background: linear-gradient(145deg, rgba(18, 18, 26, 0.98), rgba(10, 10, 15, 0.98));
    padding: 3rem;
    border-radius: 20px;
    border: 2px solid rgba(201, 162, 39, 0.3);
    max-width: 600px;
    width: 100%;
    transform: scale(0.9) translateY(40px);
    opacity: 0;
    position: relative;
    transition: all var(--transition-slow);
    box-shadow: 
        0 32px 80px rgba(0, 0, 0, 0.8),
        0 0 60px rgba(201, 162, 39, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
}

.modal-overlay.active .modal-content {
    transform: scale(1) translateY(0);
    opacity: 1;
}

.modal-content::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 20px;
    padding: 2px;
    background: linear-gradient(135deg, var(--gold), transparent, var(--gold));
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0.3;
    pointer-events: none;
}

.modal-content img {
    max-width: 150px;
    margin: 0 auto 2rem;
    display: block;
    filter: drop-shadow(0 8px 24px rgba(201, 162, 39, 0.4));
    animation: modalImageFloat 3s ease-in-out infinite;
}

@keyframes modalImageFloat {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

.modal-content h2 {
    font-family: "Cinzel Decorative", serif;
    font-size: 2rem;
    text-align: center;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, var(--gold), var(--gold-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.modal-content p {
    text-align: center;
    color: var(--gray-light);
    font-size: 1.2rem;
    margin-bottom: 1rem;
    line-height: 1.8;
}

.close-modal {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(139, 0, 0, 0.3);
    border: 2px solid rgba(201, 162, 39, 0.3);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    font-size: 28px;
    color: var(--light);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-normal);
    backdrop-filter: blur(10px);
}

.close-modal:hover {
    background: var(--blood-red);
    border-color: var(--gold);
    transform: rotate(90deg) scale(1.1);
    box-shadow: 0 0 30px rgba(139, 0, 0, 0.6);
}

.modal-content.stark {
    background: linear-gradient(145deg, rgba(30, 41, 59, 0.98), rgba(15, 23, 42, 0.98));
    border-color: var(--ice-blue);
}

.modal-content.lannister {
    background: linear-gradient(145deg, rgba(127, 29, 29, 0.95), rgba(92, 0, 0, 0.98));
    border-color: var(--gold);
}

.modal-content.targaryen {
    background: linear-gradient(145deg, rgba(69, 10, 10, 0.95), rgba(18, 18, 26, 0.98));
    border-color: var(--blood-red-light);
}

.modal-content.baratheon {
    background: linear-gradient(145deg, rgba(63, 63, 70, 0.95), rgba(24, 24, 27, 0.98));
}

.modal-content.greyjoy {
    background: linear-gradient(145deg, rgba(15, 23, 42, 0.98), rgba(10, 10, 15, 0.98));
    border-color: var(--ice-blue-dark);
}

.modal-content.tyrell {
    background: linear-gradient(145deg, rgba(20, 83, 45, 0.95), rgba(10, 40, 20, 0.98));
    border-color: #86efac;
}

body.modal-open {
    overflow: hidden;
}

.characters {
    padding: 8rem 2rem;
    position: relative;
}

.characters::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80%;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(201, 162, 39, 0.3), transparent);
}

.characters h2 {
    text-align: center;
    font-family: "Cinzel Decorative", serif;
    font-size: clamp(2.5rem, 5vw, 3.5rem);
    margin-bottom: 4rem;
    background: linear-gradient(135deg, var(--gold-dark), var(--gold-light), var(--gold-dark));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.characters-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
    max-width: 1400px;
    margin: 0 auto;
}

.character-card {
    background: linear-gradient(145deg, rgba(26, 26, 40, 0.9), rgba(18, 18, 26, 0.95));
    border: 1px solid rgba(201, 162, 39, 0.1);
    border-radius: 16px;
    overflow: hidden;
    text-align: center;
    cursor: pointer;
    height: 400px;
    position: relative;
    transition: all var(--transition-slow);
}

.character-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, transparent 50%, rgba(10, 10, 15, 0.95) 100%);
    z-index: 1;
    pointer-events: none;
}

.character-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: all var(--transition-slow);
    filter: grayscale(20%) contrast(110%);
}

.character-card:hover {
    transform: translateY(-10px) scale(1.02);
    border-color: var(--gold);
    box-shadow: 
        0 20px 50px rgba(0, 0, 0, 0.7),
        0 0 40px rgba(201, 162, 39, 0.2);
}

.character-card:hover img {
    transform: scale(1.1);
    filter: grayscale(0%) contrast(120%);
}

.character-card h3 {
    position: absolute;
    bottom: 60px;
    left: 0;
    right: 0;
    z-index: 2;
    font-family: "Cinzel", serif;
    font-size: 1.3rem;
    color: var(--light);
    margin: 0;
    padding: 0 1rem;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.8);
    transition: var(--transition-normal);
}

.character-card:hover h3 {
    color: var(--gold-light);
    text-shadow: 
        2px 2px 8px rgba(0, 0, 0, 0.8),
        0 0 20px rgba(201, 162, 39, 0.6);
}

.character-card span {
    position: absolute;
    bottom: 35px;
    left: 0;
    right: 0;
    z-index: 2;
    font-size: 0.95rem;
    color: var(--gray-light);
    font-style: italic;
    text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.8);
}

.character-card p {
    display: none;
}

.map-section {
    padding: 8rem 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
}

.map-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80%;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(201, 162, 39, 0.3), transparent);
}

.map-section h2 {
    font-family: "Cinzel Decorative", serif;
    font-size: clamp(2.5rem, 5vw, 3.5rem);
    margin-bottom: 3rem;
    background: linear-gradient(135deg, var(--gold-dark), var(--gold-light), var(--gold-dark));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.map-container {
    max-width: 800px;
    width: 100%;
    position: relative;
    border-radius: 16px;
    overflow: hidden;
    border: 2px solid rgba(201, 162, 39, 0.3);
    box-shadow: 
        0 24px 60px rgba(0, 0, 0, 0.6),
        0 0 40px rgba(201, 162, 39, 0.2);
    transition: all var(--transition-slow);
}

.map-container:hover {
    transform: scale(1.02);
    border-color: var(--gold);
    box-shadow: 
        0 32px 80px rgba(0, 0, 0, 0.7),
        0 0 60px rgba(201, 162, 39, 0.4);
}

.map-image {
    width: 100%;
    height: auto;
    display: block;
    filter: sepia(20%) contrast(110%);
    transition: filter var(--transition-slow);
}

.map-container:hover .map-image {
    filter: sepia(0%) contrast(120%);
}

.footer {
    padding: 4rem 2rem;
    text-align: center;
    font-size: 1rem;
    color: var(--gray);
    border-top: 1px solid rgba(201, 162, 39, 0.2);
    background: linear-gradient(to bottom, transparent, rgba(10, 10, 15, 0.8));
    position: relative;
}

.footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 200px;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--gold), transparent);
}

.footer p {
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.8;
}

@media (max-width: 1024px) {
    .houses-grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
        gap: 2rem;
    }
    
    .characters-grid {
        grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    }
}

@media (max-width: 768px) {
    .nav-list {
        display: none;
        flex-direction: column;
        gap: 1.5rem;
        background: rgba(10, 10, 15, 0.98);
        backdrop-filter: blur(20px);
        position: absolute;
        top: 80px;
        right: 20px;
        padding: 2rem;
        border-radius: 12px;
        border: 2px solid rgba(201, 162, 39, 0.3);
        box-shadow: var(--shadow-xl);
    }

    .nav-list.active {
        display: flex;
    }

    .menu-toggle {
        display: block;
    }
    
    .hero {
        height: 90vh;
        background-size: 300px;
    }
    
    .hero h2 {
        font-size: 2.5rem;
    }
    
    .houses,
    .characters,
    .map-section {
        padding: 4rem 1rem;
    }
    
    .modal-content {
        padding: 2rem;
        margin: 1rem;
    }
    
    .filters {
        gap: 0.75rem;
    }
    
    .filters button {
        padding: 0.6rem 1.2rem;
        font-size: 0.85rem;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 1rem;
    }
    
    .hero h2 {
        font-size: 2rem;
    }
    
    .hero p {
        font-size: 1.1rem;
    }
    
    .btn-primary {
        padding: 1rem 2rem;
        font-size: 0.95rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .house-card {
        min-height: 340px;
    }
    
    .character-card {
        height: 350px;
    }
}

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

.fade-in-up {
    animation: fadeInUp 0.8s ease-out;
}

[data-reveal] {
    opacity: 0;
    transform: translateY(40px);
    transition: all 0.8s ease-out;
}

[data-reveal].revealed {
    opacity: 1;
    transform: translateY(0);
}

*:focus-visible {
    outline: 2px solid var(--gold);
    outline-offset: 4px;
}

/* Redução de movimento para acessibilidade */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

#loading-screen {
    position: fixed;
    inset: 0;
    background: linear-gradient(135deg, #000000 0%, #1a1a2e 50%, #0f0f1e 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    transition: opacity 1s ease;
}

#loading-screen.fade-out {
    opacity: 0;
    pointer-events: none;
}

.loading-logo {
    width: 300px;
    height: auto;
    margin-bottom: 3rem;
    animation: pulse 2s ease-in-out infinite;
    filter: drop-shadow(0 0 30px rgba(153, 27, 27, 0.5));
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        opacity: 0.9;
    }
    50% {
        transform: scale(1.05);
        opacity: 1;
    }
}

.loading-container {
    text-align: center;
    max-width: 500px;
    width: 90%;
}

.loading-title {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: #fff;
    text-shadow: 0 0 20px rgba(153, 27, 27, 0.8);
    font-family: "Cinzel Decorative", serif;
    letter-spacing: 2px;
}

.loading-subtitle {
    font-size: 1.2rem;
    color: var(--gray);
    margin-bottom: 3rem;
    font-style: italic;
}

.loading-progress {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 1.5rem;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
}

.loading-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #991b1b, #dc2626, #991b1b);
    width: 0%;
    transition: width 0.3s ease;
    border-radius: 10px;
    box-shadow: 0 0 20px rgba(153, 27, 27, 0.8);
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% {
        background-position: -100% 0;
    }
    100% {
        background-position: 200% 0;
    }
}

.loading-text {
    color: #fff;
    font-size: 1rem;
    margin-bottom: 2rem;
    min-height: 24px;
    opacity: 0.8;
}

.enter-button {
    background: linear-gradient(135deg, #991b1b, #dc2626);
    color: #fff;
    border: 2px solid rgba(255, 255, 255, 0.3);
    padding: 1rem 3rem;
    font-size: 1.2rem;
    font-weight: bold;
    border-radius: 8px;
    cursor: pointer;
    font-family: "Cinzel Decorative", serif;
    letter-spacing: 1px;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.3s ease;
    box-shadow: 0 10px 30px rgba(153, 27, 27, 0.4);
    position: relative;
    overflow: hidden;
}

.enter-button::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.enter-button:hover::before {
    width: 300px;
    height: 300px;
}

.enter-button.visible {
    opacity: 1;
    transform: translateY(0);
}

.enter-button:hover {
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 15px 40px rgba(153, 27, 27, 0.6);
    border-color: rgba(255, 255, 255, 0.5);
}

.enter-button:active {
    transform: translateY(-1px) scale(1.02);
}

/* Partículas de neve/cinzas */
.loading-particles {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
}

.particle {
    position: absolute;
    width: 3px;
    height: 3px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    animation: fall linear infinite;
}

@keyframes fall {
    to {
        transform: translateY(100vh);
        opacity: 0;
    }
}

.loading-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(153, 27, 27, 0.2) 0%, transparent 70%);
    transform: translate(-50%, -50%);
    animation: rotate 20s linear infinite;
}

@keyframes rotate {
    from {
        transform: translate(-50%, -50%) rotate(0deg);
    }
    to {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}

.music-control {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: rgba(0, 0, 0, 0.7);
    border: 2px solid rgba(153, 27, 27, 0.5);
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 1000;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.music-control:hover {
    background: rgba(153, 27, 27, 0.8);
    transform: scale(1.1);
    box-shadow: 0 0 20px rgba(153, 27, 27, 0.6);
}

.music-control svg {
    width: 24px;
    height: 24px;
    fill: #fff;
}

.music-control.playing svg {
    animation: pulse-music 1s ease-in-out infinite;
}

@keyframes pulse-music {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

@media (max-width: 768px) {
    .loading-logo {
        width: 200px;
    }
    
    .loading-title {
        font-size: 1.8rem;
    }
    
    .loading-subtitle {
        font-size: 1rem;
    }
    
    .enter-button {
        padding: 0.8rem 2rem;
        font-size: 1rem;
    }
    
    .music-control {
        bottom: 20px;
        right: 20px;
        width: 50px;
        height: 50px;
    }
}


