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

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

body {
    font-family: 'Space Grotesk', sans-serif;
    background: linear-gradient(165deg, #1a1410 0%, #2d1f1a 30%, #3a2820 60%, #2d1f1a 100%);
    color: #E8DCC4;
    overflow-x: hidden;
    position: relative;
    min-height: 100vh;
}

/* Architectural grid pattern overlay */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        linear-gradient(0deg, rgba(139, 90, 60, 0.08) 1px, transparent 1px),
        linear-gradient(90deg, rgba(139, 90, 60, 0.08) 1px, transparent 1px),
        linear-gradient(0deg, rgba(101, 67, 33, 0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(101, 67, 33, 0.04) 1px, transparent 1px);
    background-size: 100px 100px, 100px 100px, 20px 20px, 20px 20px;
    pointer-events: none;
    z-index: 0;
    opacity: 0.4;
}

/* Subtle ambient glow */
body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        radial-gradient(ellipse at 15% 25%, rgba(139, 90, 60, 0.12) 0%, transparent 45%),
        radial-gradient(ellipse at 85% 70%, rgba(101, 67, 33, 0.1) 0%, transparent 50%),
        radial-gradient(ellipse at 50% 50%, rgba(160, 120, 90, 0.08) 0%, transparent 60%);
    animation: ambientShift 20s ease-in-out infinite alternate;
    pointer-events: none;
    z-index: 0;
}

@keyframes ambientShift {
    0% {
        opacity: 0.5;
        transform: scale(1);
    }

    100% {
        opacity: 0.7;
        transform: scale(1.1);
    }
}

.content-wrapper {
    position: relative;
    z-index: 1;
}

/* Modern Header Design */
header {
    background: rgba(20, 15, 12, 0.92);
    backdrop-filter: blur(30px);
    -webkit-backdrop-filter: blur(30px);
    border-bottom: 1px solid rgba(139, 90, 60, 0.3);
    padding: 1.5rem 3rem;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4),
        0 0 80px rgba(139, 90, 60, 0.08) inset;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}

.site-branding {
    flex: 1;
    min-width: 200px;
}

.site-title a {
    text-decoration: none;
    font-size: 2.8rem;
    font-weight: 700;
    font-family: 'Cinzel', serif;
    background: linear-gradient(135deg, #C9A66B 0%, #A0785A 50%, #8B5A3C 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: 12px;
    text-transform: uppercase;
    transition: all 0.5s ease;
    position: relative;
    filter: drop-shadow(0 0 20px rgba(201, 166, 107, 0.2));
}

.site-title a:hover {
    filter: drop-shadow(0 0 30px rgba(201, 166, 107, 0.4));
    letter-spacing: 16px;
}

.site-tagline {
    font-size: 1rem;
    color: #A0785A;
    letter-spacing: 5px;
    text-transform: uppercase;
    margin-top: 0.5rem;
    font-weight: 400;
    font-family: 'Space Grotesk', sans-serif;
}

/* Navigation Menu */
#menu {
    flex: 1;
    display: flex;
    justify-content: flex-end;
}

#menu ul {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    margin: 0;
    padding: 0;
    justify-content: flex-end;
}

#menu li {
    margin: 0 1.5rem;
    font-size: 1rem;
    line-height: 2.5rem;
    position: relative;
}

#menu li::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 1px;
    background: linear-gradient(90deg, #C9A66B, #A0785A);
    transition: width 0.4s ease;
    box-shadow: 0 0 8px rgba(201, 166, 107, 0.4);
}

#menu li:hover::before {
    width: 100%;
}

#menu a {
    text-decoration: none;
    color: #C9A66B;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight: 500;
    transition: all 0.3s ease;
    font-family: 'Space Grotesk', sans-serif;
}

#menu li:hover a {
    color: #E8DCC4;
    text-shadow: 0 0 12px rgba(201, 166, 107, 0.3);
}

/* Hero Section */
.hero-section {
    text-align: center;
    padding: 6rem 2rem 5rem;
    position: relative;
    overflow: hidden;
    background: linear-gradient(165deg, rgba(26, 20, 16, 0.8) 0%, rgba(45, 31, 26, 0.6) 100%);
}

.hero-title {
    font-size: 8rem;
    font-weight: 800;
    font-family: 'Cinzel', serif;
    background: linear-gradient(135deg, #C9A66B 0%, #D4AF6A 30%, #A0785A 70%, #8B5A3C 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 2rem;
    text-transform: uppercase;
    letter-spacing: 28px;
    position: relative;
    filter: drop-shadow(0 0 30px rgba(201, 166, 107, 0.25));
    animation: titlePulse 6s ease-in-out infinite;
}

@keyframes titlePulse {

    0%,
    100% {
        filter: drop-shadow(0 0 30px rgba(201, 166, 107, 0.25));
        transform: scale(1);
    }

    50% {
        filter: drop-shadow(0 0 45px rgba(201, 166, 107, 0.4));
        transform: scale(1.015);
    }
}

.hero-subtitle {
    font-size: 1.8rem;
    color: #A0785A;
    letter-spacing: 10px;
    text-transform: uppercase;
    font-weight: 400;
    margin-top: 2rem;
    text-shadow: 0 0 15px rgba(160, 120, 90, 0.2);
    font-family: 'Space Grotesk', sans-serif;
}

/* Architectural Door SVG */
.door-svg {
    width: 100%;
    height: 420px;
    margin-top: 4rem;
}

.door-frame {
    fill: none;
    stroke: #C9A66B;
    stroke-width: 2.5;
    opacity: 0;
    stroke-dasharray: 3000;
    stroke-dashoffset: 3000;
    animation: drawFrame 4s ease-out forwards;
}

@keyframes drawFrame {
    to {
        stroke-dashoffset: 0;
        opacity: 1;
    }
}

.door-frame:nth-child(2) {
    animation-delay: 0.3s;
    stroke: #A0785A;
}

.door-frame:nth-child(3) {
    animation-delay: 0.6s;
    stroke: #8B5A3C;
}

.door-panel {
    fill: rgba(160, 120, 90, 0.18);
    stroke: #8B5A3C;
    stroke-width: 1.5;
    opacity: 0;
    animation: revealPanel 2.5s ease-out forwards;
}

.door-panel:nth-child(1) {
    animation-delay: 1s;
}

.door-panel:nth-child(2) {
    animation-delay: 1.2s;
}

.door-panel:nth-child(3) {
    animation-delay: 1.4s;
}

@keyframes revealPanel {
    from {
        opacity: 0;
        transform: scale(0.95);
    }

    to {
        opacity: 0.9;
        transform: scale(1);
    }
}

.door-detail {
    stroke: #C9A66B;
    stroke-width: 1.5;
    opacity: 0;
    animation: fadeDetail 2s ease-out forwards;
    stroke-linecap: round;
}

.door-detail:nth-child(1) {
    animation-delay: 1.6s;
}

.door-detail:nth-child(2) {
    animation-delay: 1.8s;
}

.door-detail:nth-child(3) {
    animation-delay: 2s;
}

@keyframes fadeDetail {
    from {
        opacity: 0;
    }

    to {
        opacity: 0.8;
    }
}

.door-handle {
    fill: #C9A66B;
    stroke: #8B5A3C;
    stroke-width: 1;
    opacity: 0;
    animation: appearHandle 2s ease-out forwards;
}

.door-handle:nth-child(1) {
    animation-delay: 2.2s;
}

@keyframes appearHandle {
    from {
        opacity: 0;
        transform: translateX(-10px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.threshold {
    fill: rgba(139, 90, 60, 0.4);
    stroke: #8B5A3C;
    stroke-width: 2;
    opacity: 0;
    animation: solidifyBase 2.5s ease-out forwards;
    animation-delay: 2.5s;
}

@keyframes solidifyBase {
    from {
        opacity: 0;
    }

    to {
        opacity: 0.9;
    }
}

/* Gallery Section */
.door-gallery {
    max-width: 1600px;
    margin: 3rem auto;
    padding: 0 2rem 4rem;
}

.region-section {
    margin-bottom: 5rem;
}

.region-title {
    font-size: 3rem;
    font-weight: 700;
    font-family: 'Cinzel', serif;
    background: linear-gradient(135deg, #C9A66B 0%, #A0785A 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-transform: uppercase;
    letter-spacing: 8px;
    margin-bottom: 3rem;
    position: relative;
    padding-left: 25px;
}

.region-title::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 6px;
    height: 85%;
    background: linear-gradient(180deg, #C9A66B, #8B5A3C);
    box-shadow: 0 0 15px rgba(201, 166, 107, 0.4);
    border-radius: 8px;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
    gap: 2.5rem;
    margin-top: 2rem;
    justify-items: center;
}

.gallery-grid .door-card {
    max-width: 480px;
    width: 100%;
}

/* Door Card Design */
.door-card {
    position: relative;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    isolation: isolate;
    z-index: 1;
}

.door-card:hover {
    transform: translateY(-15px) scale(1.03);
    z-index: 10;
}

/* Card container with architectural frame */
.card-container {
    display: flex;
    flex-direction: column;
    position: relative;
    background: linear-gradient(165deg, rgba(35, 25, 20, 0.95) 0%, rgba(45, 31, 26, 0.92) 100%);
    border-radius: 12px;
    border: 1px solid rgba(139, 90, 60, 0.25);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5),
        0 0 30px rgba(139, 90, 60, 0.1) inset;
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
}

.door-card:hover .card-container {
    border-color: rgba(201, 166, 107, 0.4);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6),
        0 0 50px rgba(201, 166, 107, 0.15) inset;
}

/* Architectural lines overlay */
.arch-lines {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 100%;
    z-index: 2;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.7s ease;
}

.door-card:hover .arch-lines {
    opacity: 1;
}

.arch-line {
    position: absolute;
    background: linear-gradient(90deg, transparent, rgba(201, 166, 107, 0.15), transparent);
    width: 1px;
    height: 100%;
    animation: archMove 4s ease-in-out infinite;
}

.arch-line:nth-child(1) {
    left: 20%;
    animation-delay: 0s;
}

.arch-line:nth-child(2) {
    left: 50%;
    background: linear-gradient(90deg, transparent, rgba(160, 120, 90, 0.2), transparent);
    width: 2px;
    animation-delay: 0.8s;
}

.arch-line:nth-child(3) {
    left: 80%;
    animation-delay: 1.6s;
}

@keyframes archMove {

    0%,
    100% {
        opacity: 0.3;
        transform: scaleY(1);
    }

    50% {
        opacity: 0.8;
        transform: scaleY(1.05);
    }
}

/* Portal opening effect */
.portal-sweep {
    position: absolute;
    top: -100%;
    left: 0;
    right: 0;
    height: 100%;
    background: linear-gradient(180deg,
            transparent,
            rgba(201, 166, 107, 0.12),
            rgba(160, 120, 90, 0.1),
            transparent);
    z-index: 3;
    pointer-events: none;
}

.door-card:hover .portal-sweep {
    animation: portalOpen 3s ease-in-out;
}

@keyframes portalOpen {
    0% {
        top: -100%;
    }

    100% {
        top: 100%;
    }
}

/* Image Container */
.door-image-wrapper {
    position: relative;
    width: 100%;
    aspect-ratio: 4/3;
    overflow: hidden;
    border-radius: 12px;
}

/* Portrait orientation - manually add this class to portrait images */
.door-image-wrapper.portrait {
    aspect-ratio: 3/4;
}

.door-image-wrapper::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(165deg,
            rgba(139, 90, 60, 0.15) 0%,
            transparent 50%,
            rgba(101, 67, 33, 0.12) 100%);
    z-index: 1;
    pointer-events: none;
    opacity: 0.5;
    transition: opacity 0.6s ease;
}

.door-card:hover .door-image-wrapper::before {
    opacity: 0.7;
}

.door-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: all 1.2s cubic-bezier(0.4, 0, 0.2, 1);
    filter: saturate(0.85) contrast(1.1) brightness(0.95);
}

.door-card:hover .door-image {
    transform: scale(1.15);
    filter: saturate(1.1) contrast(1.15) brightness(1);
}

/* Info Overlay */
.door-info {
    position: relative;
    padding: 2.5rem;
    z-index: 5;
    background: linear-gradient(to top,
            rgba(20, 15, 12, 0.96) 0%,
            rgba(35, 25, 20, 0.9) 70%,
            transparent 100%);
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border-radius: 0 0 12px 12px;
    border-top: 1px solid rgba(139, 90, 60, 0.2);
    transform: translateY(0);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    flex-shrink: 0;
}

.door-location {
    font-size: 2rem;
    font-weight: 600;
    font-family: 'Cinzel', serif;
    color: #C9A66B;
    letter-spacing: 4px;
    text-transform: uppercase;
    margin: 0;
    transition: all 0.4s ease;
    text-shadow: 0 0 15px rgba(201, 166, 107, 0.2);
}

.door-card:hover .door-location {
    color: #E8DCC4;
    text-shadow: 0 0 25px rgba(201, 166, 107, 0.4);
}

/* Decorative corner brackets */
.door-bracket {
    position: absolute;
    z-index: 4;
    pointer-events: none;
    transition: all 0.6s ease;
}

.bracket-tl,
.bracket-br,
.bracket-tr,
.bracket-bl {
    width: 40px;
    height: 40px;
    border: 2px solid rgba(139, 90, 60, 0.3);
    border-radius: 3px;
}

.bracket-tl {
    top: 12px;
    left: 12px;
    border-right: none;
    border-bottom: none;
}

.bracket-tr {
    top: 12px;
    right: 12px;
    border-left: none;
    border-bottom: none;
}

.bracket-bl {
    bottom: 12px;
    left: 12px;
    border-right: none;
    border-top: none;
}

.bracket-br {
    bottom: 12px;
    right: 12px;
    border-left: none;
    border-top: none;
}

.door-card:hover .door-bracket {
    border-color: rgba(201, 166, 107, 0.6);
    box-shadow: 0 0 15px rgba(201, 166, 107, 0.3);
}

.door-card:hover .bracket-tl,
.door-card:hover .bracket-br {
    width: 50px;
    height: 50px;
}

.door-card:hover .bracket-tr,
.door-card:hover .bracket-bl {
    width: 50px;
    height: 50px;
}

/* Portrait-specific styling */
.portrait {
    height: 520px;
}

/* Footer */
footer {
    background: linear-gradient(165deg, rgba(20, 15, 12, 0.95) 0%, rgba(35, 25, 20, 0.95) 100%);
    backdrop-filter: blur(30px);
    -webkit-backdrop-filter: blur(30px);
    border-top: 1px solid rgba(139, 90, 60, 0.3);
    padding: 3rem 2rem;
    margin-top: 4rem;
    text-align: center;
    box-shadow: 0 -8px 32px rgba(0, 0, 0, 0.4);
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
}

.footer-title {
    font-size: 1.6rem;
    font-family: 'Cinzel', serif;
    background: linear-gradient(135deg, #C9A66B 0%, #A0785A 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: 6px;
    text-transform: uppercase;
    margin-bottom: 1.5rem;
    font-weight: 600;
}

#langlist {
    display: inline-flex;
    flex-wrap: wrap;
    justify-content: center;
    background: rgba(35, 25, 20, 0.8);
    border-radius: 40px;
    padding: 0.5rem;
    border: 1px solid rgba(139, 90, 60, 0.25);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    margin-bottom: 2rem;
    box-shadow: 0 0 30px rgba(139, 90, 60, 0.1) inset;
}

#langlist li {
    display: inline-block;
    list-style: none;
    margin: 0.3rem;
    padding: 0.8rem 1.4rem;
    border-radius: 25px;
    transition: all 0.4s ease;
}

#langlist a {
    text-decoration: none;
    color: #C9A66B;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    font-weight: 500;
    font-family: 'Space Grotesk', sans-serif;
}

#langlist .highlight {
    background: linear-gradient(135deg, #C9A66B, #A0785A);
    box-shadow: 0 0 20px rgba(201, 166, 107, 0.25);
}

#langlist .highlight a {
    color: #1a1410;
    font-weight: 600;
}

#langlist li:not(.highlight):hover {
    background: rgba(139, 90, 60, 0.3);
    box-shadow: 0 0 15px rgba(139, 90, 60, 0.2);
}

#langlist li:not(.highlight):hover a {
    color: #E8DCC4;
    text-shadow: 0 0 10px rgba(201, 166, 107, 0.3);
}

.footer-credits {
    color: #A0785A;
    font-size: 0.95rem;
    letter-spacing: 2px;
    margin-top: 2rem;
    font-weight: 400;
    font-family: 'Space Grotesk', sans-serif;
}

.footer-credits strong {
    background: linear-gradient(135deg, #C9A66B 0%, #A0785A 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 600;
    font-family: 'Cinzel', serif;
}

/* Responsive Design */
@media screen and (max-width: 968px) {
    header {
        flex-direction: column;
        text-align: center;
        padding: 1.5rem 1rem;
    }

    .site-branding {
        margin-bottom: 1rem;
    }

    #menu {
        justify-content: center;
    }

    #menu ul {
        justify-content: center;
    }

    .gallery-grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
        gap: 2rem;
    }

    .hero-title {
        font-size: 4.5rem;
        letter-spacing: 15px;
    }

    .hero-subtitle {
        font-size: 1.4rem;
        letter-spacing: 6px;
    }

    .door-card {
        }

    .door-location {
        font-size: 1.7rem;
    }
}

@media screen and (max-width: 600px) {
    .site-title a {
        font-size: 2rem;
        letter-spacing: 6px;
    }

    .site-tagline {
        font-size: 0.85rem;
    }

    #menu li {
        margin: 0 0.8rem;
        font-size: 0.9rem;
    }

    .hero-title {
        font-size: 3rem;
        letter-spacing: 8px;
    }

    .hero-subtitle {
        font-size: 1.1rem;
        letter-spacing: 4px;
    }

    .gallery-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .door-card {
        }

    .portrait {
        height: 440px;
    }

    .door-location {
        font-size: 1.5rem;
    }

    .door-info {
        padding: 2rem;
    }

    .region-title {
        font-size: 2.2rem;
    }
}
