:root {
    --bg-color: #f2ebe4;
    --text-color: #421417;
    --accent-color: #641b1f;
    --secondary-accent: #8b642e;
    --frame-border: #a8792f;
    --nav-bg: rgba(247, 240, 233, 0.88);
    --panel-bg: rgba(255, 250, 244, 0.68);
}

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

body {
    font-family: 'Lato', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    background-image:
        linear-gradient(rgba(247, 240, 233, 0.58), rgba(247, 240, 233, 0.58)),
        url("site-background.png");
    background-attachment: fixed;
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
}

/* Landing Page */
.landing-page {
    background: #efe8df;
    color: var(--accent-color);
    height: 100vh;
    overflow: hidden;
}

.landing-stage {
    height: 100vh;
    width: 100%;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.landing-full-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
}

.landing-enter {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: absolute;
    left: 28%;
    bottom: clamp(1.2rem, 3vh, 2.4rem);
    transform: translate(-50%, -50%);
    min-width: 132px;
    min-height: 46px;
    border: 1px solid rgba(100, 27, 31, 0.45);
    border-radius: 999px;
    color: var(--accent-color);
    text-decoration: none;
    font-family: Garamond, Georgia, 'Times New Roman', serif;
    font-size: 0.95rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    background: rgba(255, 250, 244, 0.68);
    box-shadow: 0 16px 32px rgba(82, 20, 22, 0.065);
    transition: background-color 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.landing-enter:hover,
.landing-enter:focus-visible {
    border-color: var(--secondary-accent);
    background: rgba(255, 250, 244, 0.9);
    box-shadow: 0 18px 36px rgba(82, 20, 22, 0.12);
}

/* Navigation Bar */
.navbar {
    background-color: var(--nav-bg);
    min-height: 116px;
    padding: 1rem 4%;
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid rgba(100, 27, 31, 0.16);
    box-shadow: 0 6px 18px rgba(82, 20, 22, 0.08);
    display: flex;
    justify-content: space-between;
    align-items: center;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.navbar-logo {
    text-decoration: none;
    display: flex;
    align-items: center;
}

.circular-logo {
    width: 96px;
    height: 96px;
    border-radius: 6px;
    border: 2px solid var(--accent-color);
    background: rgba(255, 250, 244, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 8px 18px rgba(82, 20, 22, 0.14);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    overflow: hidden;
}

.circular-logo:hover {
    transform: scale(1.03);
    box-shadow: 0 10px 22px rgba(82, 20, 22, 0.2);
}

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

.logo-symbol {
    font-family: 'Cinzel', serif;
    color: var(--accent-color);
    font-weight: bold;
    font-size: 1.1rem;
}

.nav-links {
    display: flex;
    flex-wrap: wrap;
    gap: 2.1rem;
    align-items: center;
    justify-content: flex-end;
}

.nav-item {
    color: var(--text-color);
    text-decoration: none;
    font-family: 'Cinzel', serif;
    font-size: 1.32rem;
    font-weight: 700;
    letter-spacing: 1.8px;
    transition: color 0.3s ease, text-shadow 0.3s ease;
    min-width: 150px;
    padding: 0.72rem 1.55rem;
    border-radius: 4px;
    text-align: center;
}

.nav-item:hover {
    color: var(--accent-color);
    text-shadow: 0 0 8px rgba(168, 121, 47, 0.22);
    background-color: rgba(100, 27, 31, 0.06);
}

/* Main Content Layout (Scrolling Page) */
.main-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    padding: 2.5rem 5%;
    width: 100%;
}

.home-layout {
    display: grid;
    grid-template-columns: 1.3fr 2fr 1.3fr;
    gap: 6rem;
    min-height: calc(100vh - 160px);
    align-items: center;
    width: 100%;
    margin-bottom: 4rem;
    padding: 0 1rem;
}

/* Columns */
.home-column {
    height: calc(100vh - 180px);
    min-height: 500px;
    border: 3px double var(--frame-border);
    background: var(--panel-bg);
    border-radius: 8px;
    box-shadow: 0 12px 30px rgba(82, 20, 22, 0.08);
    padding: 2rem 1.5rem;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow-y: auto;
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.home-column:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 36px rgba(82, 20, 22, 0.14);
}

.center-column {
    text-align: center;
    z-index: 10;
    animation: fadeIn 1.5s ease-out;
}

/* Announcements Column Content */
.column-title {
    font-family: 'Cinzel', serif;
    color: var(--accent-color);
    text-align: center;
    font-size: 1.85rem;
    margin-bottom: 2rem;
    border-bottom: 2px solid rgba(100, 27, 31, 0.16);
    padding-bottom: 0.75rem;
    letter-spacing: 1px;
}

.announcement-list {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.announcement-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.announcement-arrow {
    width: 0.8rem;
    height: 0.8rem;
    margin-top: 0.62rem;
    background: var(--accent-color);
    border: 1px solid rgba(168, 121, 47, 0.55);
    flex: 0 0 auto;
}

.announcement-item p {
    font-size: 1.65rem;
    font-weight: 600;
    line-height: 1.65;
}

@keyframes arrowPulse {
    from {
        transform: translateX(0);
        opacity: 0.6;
    }

    to {
        transform: translateX(4px);
        opacity: 1;
    }
}

/* Symmetrical Right Column with Photo Frames of Equal Sizes */
.gallery-frames {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    height: 100%;
}

.gallery-photo-frame {
    flex: 1;
    border: 2px dashed rgba(168, 121, 47, 0.42);
    border-radius: 6px;
    display: flex;
    justify-content: center;
    align-items: center;
    background: rgba(255, 250, 244, 0.45);
    transition: all 0.3s ease;
    cursor: pointer;
}

.gallery-photo-frame:hover {
    background: rgba(255, 250, 244, 0.74);
    border-color: var(--accent-color);
    box-shadow: inset 0 0 15px rgba(100, 27, 31, 0.08);
}

.gallery-photo-frame.has-image {
    border-style: solid;
    padding: 0.35rem;
    overflow: hidden;
}

.zoomable-gallery-frame {
    cursor: zoom-in;
}

.zoomable-gallery-frame:focus-visible {
    outline: 3px solid rgba(100, 27, 31, 0.36);
    outline-offset: 3px;
}

.gallery-photo-frame img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 4px;
}

.gallery-zoom-modal {
    position: fixed;
    inset: 0;
    z-index: 2000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: clamp(1rem, 4vw, 3rem);
    background: rgba(22, 12, 10, 0.82);
}

.gallery-zoom-modal.active {
    display: flex;
}

.gallery-zoom-image {
    width: auto;
    max-width: min(94vw, 1200px);
    max-height: 88vh;
    border: 3px solid rgba(255, 250, 244, 0.86);
    border-radius: 8px;
    background: rgba(255, 250, 244, 0.9);
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
    object-fit: contain;
}

.gallery-zoom-close {
    position: fixed;
    top: clamp(1rem, 3vw, 2rem);
    right: clamp(1rem, 3vw, 2rem);
    width: 3rem;
    height: 3rem;
    border: 1px solid rgba(255, 250, 244, 0.64);
    border-radius: 50%;
    background: rgba(255, 250, 244, 0.95);
    color: var(--accent-color);
    cursor: pointer;
    font-size: 2rem;
    line-height: 1;
}

.placeholder-text {
    font-family: 'Cinzel', serif;
    color: rgba(66, 20, 23, 0.34);
    font-size: 1.05rem;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.home-gallery-frames {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    overscroll-behavior: contain;
    padding-right: 0.35rem;
    scrollbar-color: rgba(100, 27, 31, 0.45) rgba(255, 250, 244, 0.5);
    scrollbar-width: thin;
}

.home-gallery-frames .gallery-photo-frame {
    flex: 0 0 clamp(220px, 35vh, 310px);
    min-height: 220px;
}

.home-gallery-frames .gallery-photo-frame.has-image {
    background: rgba(255, 250, 244, 0.74);
}

.home-gallery-frames .gallery-photo-frame img {
    object-fit: contain;
    background: rgba(255, 250, 244, 0.64);
}

.gallery-view-all {
    align-self: center;
    border: 1px solid var(--accent-color);
    border-radius: 4px;
    color: var(--accent-color);
    font-family: 'Cinzel', serif;
    font-size: 1.02rem;
    letter-spacing: 1px;
    margin-top: 1.25rem;
    padding: 0.72rem 1.3rem;
    text-decoration: none;
    text-transform: uppercase;
    transition: background-color 0.25s ease, color 0.25s ease, box-shadow 0.25s ease, transform 0.25s ease;
}

.gallery-view-all:hover,
.gallery-view-all:focus-visible {
    background: var(--accent-color);
    color: var(--bg-color);
    box-shadow: 0 10px 18px rgba(82, 20, 22, 0.14);
    transform: translateY(-1px);
}

/* Center Content Styling */
.musical-icon {
    display: none;
    font-size: 4rem;
    color: var(--accent-color);
    margin-bottom: 1rem;
    opacity: 0.8;
    text-shadow: 0 0 15px rgba(168, 121, 47, 0.25);
    animation: float 3s ease-in-out infinite;
}

.firm-name {
    font-family: Algerian, 'Cinzel', Georgia, serif;
    font-size: clamp(4.6rem, 6.6vw, 7.2rem);
    color: var(--accent-color);
    line-height: 0.95;
    margin-bottom: 1rem;
    text-shadow: 2px 2px 6px rgba(255, 250, 244, 0.7);
}

.firm-main-title {
    display: block;
    white-space: nowrap;
}

.subtitle {
    display: block;
    font-size: clamp(2.6rem, 3.8vw, 4.2rem);
    font-weight: 700;
    color: var(--accent-color);
    margin-top: 0.55rem;
    font-family: Algerian, 'Cinzel', Georgia, serif;
    letter-spacing: 0;
    text-transform: uppercase;
}

.tagline {
    font-style: italic;
    font-size: 1.5rem;
    color: rgba(66, 20, 23, 0.78);
    margin-bottom: 2rem;
    letter-spacing: 1.5px;
}

.musical-divider {
    height: 2px;
    width: 150px;
    background: linear-gradient(90deg, transparent, var(--accent-color), transparent);
    margin: 0 auto;
}

/* 4x2 Interactive Squares Grid Section */
.squares-section {
    width: 100%;
    padding: 4rem 0 2rem 0;
    border-top: 1px solid rgba(100, 27, 31, 0.14);
    margin-top: 2rem;
}

.squares-title {
    font-family: 'Cinzel', serif;
    color: var(--accent-color);
    text-align: center;
    font-size: 2.35rem;
    margin-bottom: 3rem;
    letter-spacing: 2px;
}

.squares-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2.6rem;
    max-width: 1500px;
    margin: 0 auto;
}

.grid-square {
    aspect-ratio: 1 / 1;
    min-height: 270px;
    border: 2px solid rgba(168, 121, 47, 0.32);
    background: var(--panel-bg);
    border-radius: 8px;
    display: flex;
    justify-content: center;
    align-items: center;
    text-decoration: none;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    position: relative;
    overflow: hidden;
}

.grid-square::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(168, 121, 47, 0.1), transparent);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.grid-square:hover {
    transform: translateY(-8px);
    border-color: var(--accent-color);
    box-shadow: 0 12px 24px rgba(82, 20, 22, 0.12);
}

.grid-square:hover::before {
    opacity: 1;
}

.square-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1.35rem;
    width: 100%;
    height: 100%;
    padding: 1.2rem;
    z-index: 1;
}

.square-icon {
    font-size: 2.9rem;
    filter: drop-shadow(0 0 5px rgba(255, 215, 0, 0.2));
    transition: transform 0.4s ease;
}

.grid-square:hover .square-icon {
    transform: scale(1.15) rotate(5deg);
}

.offering-icon {
    width: min(84%, 230px);
    height: 165px;
    object-fit: contain;
    display: block;
    filter: drop-shadow(0 8px 12px rgba(82, 20, 22, 0.16));
    transition: transform 0.4s ease;
}

.grid-square:hover .offering-icon {
    transform: scale(1.08);
}

.square-title {
    font-family: 'Cinzel', serif;
    color: var(--text-color);
    font-size: 1.46rem;
    font-weight: 700;
    letter-spacing: 0;
    text-transform: uppercase;
    text-align: center;
    transition: color 0.3s ease;
}

.grid-square:hover .square-title {
    color: var(--accent-color);
}

/* About Us Page Layout */
.about-section {
    flex: 1;
    padding: 4rem 5%;
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
}

.about-header {
    text-align: center;
    margin-bottom: 3.5rem;
}

.about-title {
    font-family: 'Playfair Display', serif;
    font-size: 3.5rem;
    color: var(--accent-color);
    margin-bottom: 0.5rem;
    text-shadow: 2px 2px 4px rgba(255, 250, 244, 0.64);
}

.about-container {
    width: 100%;
    display: block;
    /* Allows natural wrapping around floats */
}

.about-photo-frame {
    float: right;
    width: 320px;
    height: 420px;
    margin-left: 3.5rem;
    margin-bottom: 2rem;
    border: 3px double var(--frame-border);
    border-radius: 8px;
    display: flex;
    justify-content: center;
    align-items: center;
    background: var(--panel-bg);
    box-shadow: 0 14px 28px rgba(82, 20, 22, 0.12);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
    overflow: hidden;
}

.about-photo-frame:hover {
    transform: scale(1.02);
    box-shadow: 0 18px 36px rgba(82, 20, 22, 0.18);
}

.about-photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center top;
}

.about-text {
    font-family: 'Lato', sans-serif;
    font-size: 1.42rem;
    line-height: 1.95;
    color: var(--text-color);
    text-align: justify;
    margin-bottom: 1.35rem;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

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

@keyframes float {
    0% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }

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

/* Responsive Design */
@media (max-width: 1200px) {
    .home-layout {
        grid-template-columns: 1.2fr 2fr 1.2fr;
        gap: 1.5rem;
    }

    .squares-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 1.6rem;
    }

    .grid-square {
        min-height: 220px;
    }

    .offering-icon {
        height: 135px;
    }
}

@media (max-width: 1024px) {
    .firm-name {
        font-size: 4.2rem;
    }

    .subtitle {
        font-size: 2.6rem;
    }

    .home-layout {
        grid-template-columns: 1fr;
        height: auto;
        gap: 3rem;
    }

    .home-column {
        height: 450px;
        min-height: auto;
    }

    .squares-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .grid-square {
        min-height: 260px;
    }

    .offering-icon {
        height: 160px;
    }

    .about-photo-frame {
        width: 280px;
        height: 380px;
        margin-left: 2rem;
    }
}

@media (max-width: 768px) {
    .landing-page {
        overflow: hidden;
    }

    .landing-enter {
        left: 50%;
        bottom: 1rem;
    }

    .navbar {
        flex-direction: column;
        gap: 1.5rem;
        padding: 1.5rem 1rem;
    }

    .nav-links {
        flex-wrap: wrap;
        justify-content: center;
        gap: 0.75rem;
        font-size: 0.9rem;
    }

    .firm-name {
        font-size: 3.5rem;
    }

    .firm-main-title {
        white-space: normal;
    }

    .subtitle {
        font-size: 2.2rem;
    }

    .announcement-item p {
        font-size: 1.38rem;
    }

    .about-photo-frame {
        float: none;
        width: 100%;
        max-width: 320px;
        margin: 0 auto 2rem auto;
        height: 380px;
    }

    .about-text {
        text-align: left;
    }
}

@media (max-width: 480px) {
    .squares-grid {
        grid-template-columns: 1fr;
    }

    .grid-square {
        min-height: 245px;
    }

    .offering-icon {
        height: 150px;
    }
}

/* News & Updates Section */
.news-section {
    width: 100%;
    padding: 4rem 0;
    border-top: 1px solid rgba(100, 27, 31, 0.14);
    margin-top: 2rem;
}

.news-section-title {
    font-family: 'Cinzel', serif;
    color: var(--accent-color);
    text-align: center;
    font-size: 2.55rem;
    margin-bottom: 3.5rem;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(340px, 440px));
    justify-content: center;
    gap: 3rem;
    max-width: 1500px;
    margin: 0 auto;
}

.news-card {
    border: 2px solid rgba(168, 121, 47, 0.3);
    background: var(--panel-bg);
    border-radius: 8px;
    text-decoration: none;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    height: 100%;
}

.news-card:hover {
    transform: translateY(-8px);
    border-color: var(--accent-color);
    box-shadow: 0 12px 24px rgba(82, 20, 22, 0.14);
}

.news-image-placeholder {
    height: 245px;
    background: linear-gradient(135deg, rgba(255, 250, 244, 0.62) 0%, rgba(168, 121, 47, 0.1) 100%);
    border-bottom: 1px solid rgba(100, 27, 31, 0.14);
    display: flex;
    justify-content: flex-end;
    align-items: flex-end;
    padding: 1rem;
    position: relative;
}

.news-image {
    height: 245px;
    border-bottom: 1px solid rgba(100, 27, 31, 0.14);
    display: flex;
    justify-content: flex-end;
    align-items: flex-end;
    padding: 1rem;
    position: relative;
    overflow: hidden;
    background: rgba(255, 250, 244, 0.62);
}

.news-image img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 42%;
}

.news-image .news-date {
    position: relative;
    z-index: 1;
}

.news-image-placeholder::after {
    content: '📰';
    font-size: 3rem;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    opacity: 0.2;
}

.news-date {
    font-family: 'Cinzel', serif;
    font-size: 1.05rem;
    background: rgba(255, 250, 244, 0.88);
    color: var(--accent-color);
    padding: 0.3rem 0.8rem;
    border-radius: 4px;
    border: 1px solid rgba(100, 27, 31, 0.22);
    letter-spacing: 1px;
}

.news-info {
    padding: 2rem;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.news-title {
    font-family: 'Playfair Display', serif;
    color: var(--accent-color);
    font-size: 1.85rem;
    margin-bottom: 0.75rem;
    line-height: 1.3;
}

.news-subtitle {
    font-family: 'Cinzel', serif;
    color: var(--secondary-accent);
    font-size: 1.04rem;
    line-height: 1.45;
    letter-spacing: 0.7px;
    text-transform: uppercase;
    margin-bottom: 0.85rem;
}

.news-desc {
    font-family: 'Lato', sans-serif;
    color: var(--text-color);
    font-size: 1.24rem;
    line-height: 1.6;
    margin-bottom: 1.5rem;
    flex: 1;
    opacity: 0.85;
}

.news-more {
    font-family: 'Cinzel', serif;
    color: var(--accent-color);
    font-size: 1.1rem;
    font-weight: bold;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: gap 0.3s ease;
}

.news-card:hover .news-more {
    gap: 0.8rem;
}

@media (max-width: 1024px) {
    .news-grid {
        grid-template-columns: repeat(auto-fit, minmax(300px, 420px));
    }
}

@media (max-width: 768px) {
    .news-grid {
        grid-template-columns: minmax(0, 1fr);
    }
}

/* Achievements Section */
.achievements-section {
    width: 100%;
    padding: 4rem 0;
    border-top: 1px solid rgba(100, 27, 31, 0.14);
    margin-top: 2rem;
}

.achievements-section-title {
    font-family: 'Cinzel', serif;
    color: var(--accent-color);
    text-align: center;
    font-size: 2.55rem;
    margin-bottom: 3.5rem;
    letter-spacing: 2px;
    text-transform: uppercase;
}

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

.achievement-card {
    border: 2px solid rgba(168, 121, 47, 0.32);
    background: var(--panel-bg);
    border-radius: 8px;
    padding: 2.5rem 1.5rem;
    text-align: center;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    overflow: hidden;
    text-decoration: none;
    color: inherit;
}

button.achievement-card {
    font: inherit;
    color: inherit;
    cursor: pointer;
}

.achievement-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(168, 121, 47, 0.1), transparent);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.achievement-card:hover {
    transform: translateY(-8px);
    border-color: var(--accent-color);
    box-shadow: 0 12px 24px rgba(82, 20, 22, 0.12);
}

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

.achievement-icon {
    font-size: 3rem;
    margin-bottom: 1.5rem;
    filter: drop-shadow(0 0 5px rgba(255, 215, 0, 0.2));
    transition: transform 0.4s ease;
    z-index: 1;
}

.achievement-card:hover .achievement-icon {
    transform: scale(1.15);
}

.achievement-title {
    font-family: 'Playfair Display', serif;
    color: var(--accent-color);
    font-size: 1.58rem;
    margin-bottom: 1rem;
    line-height: 1.3;
    z-index: 1;
}

.achievement-desc {
    font-family: 'Lato', sans-serif;
    color: var(--text-color);
    font-size: 1.1rem;
    line-height: 1.6;
    opacity: 0.85;
    z-index: 1;
}

.achievement-detail {
    display: block;
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    font-size: 1.1rem;
    line-height: 1.65;
    color: var(--text-color);
    transition: max-height 0.35s ease, opacity 0.25s ease, margin-top 0.25s ease;
    z-index: 1;
}

.achievement-card.active .achievement-detail {
    max-height: 220px;
    opacity: 1;
    margin-top: 1rem;
}

.achievement-more {
    margin-top: 1.4rem;
    font-family: 'Cinzel', serif;
    color: var(--accent-color);
    font-size: 0.96rem;
    letter-spacing: 1px;
    text-transform: uppercase;
    z-index: 1;
}

.achievement-card.active .achievement-more {
    opacity: 0.65;
}

@media (max-width: 1024px) {
    .achievements-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .achievements-grid {
        grid-template-columns: 1fr;
    }
}

/* Restricted Offerings Styling */
.grid-square.restricted-course {
    position: relative;
    cursor: pointer;
}

.grid-square.restricted-course::after {
    content: 'Coming Soon';
    position: absolute;
    top: 12px;
    right: 12px;
    background: rgba(255, 250, 244, 0.68);
    border: 1px solid rgba(100, 27, 31, 0.22);
    color: var(--accent-color);
    font-family: 'Cinzel', serif;
    font-size: 0.7rem;
    padding: 2px 8px;
    border-radius: 4px;
    letter-spacing: 0.5px;
    opacity: 0.85;
    transition: opacity 0.3s ease;
}

.grid-square.restricted-course:hover::after {
    opacity: 1;
    background: rgba(255, 250, 244, 0.9);
}

/* Modal overlay and box styling */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(66, 20, 23, 0.58);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 2000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
}

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

.modal-content {
    background: rgba(255, 250, 244, 0.88);
    border: 2px solid rgba(100, 27, 31, 0.24);
    border-radius: 12px;
    box-shadow: 0 20px 40px rgba(82, 20, 22, 0.2), inset 0 0 20px rgba(168, 121, 47, 0.05);
    padding: 3rem 2.5rem;
    max-width: 500px;
    width: 90%;
    text-align: center;
    position: relative;
    transform: scale(0.8);
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

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

.modal-close {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 2rem;
    color: var(--secondary-accent);
    cursor: pointer;
    transition: color 0.3s ease;
}

.modal-close:hover {
    color: var(--accent-color);
}

.modal-icon {
    font-size: 3.5rem;
    margin-bottom: 1.5rem;
    filter: drop-shadow(0 0 10px rgba(255, 215, 0, 0.3));
    animation: float 3s ease-in-out infinite;
}

.modal-title {
    font-family: 'Playfair Display', serif;
    color: var(--accent-color);
    font-size: 2rem;
    margin-bottom: 1rem;
    letter-spacing: 1px;
}

.modal-text {
    font-family: 'Lato', sans-serif;
    color: var(--text-color);
    font-size: 1.1rem;
    line-height: 1.7;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.modal-btn {
    font-family: 'Cinzel', serif;
    background: transparent;
    color: var(--accent-color);
    border: 1px solid var(--accent-color);
    padding: 0.6rem 2rem;
    font-size: 1rem;
    border-radius: 4px;
    cursor: pointer;
    letter-spacing: 1.5px;
    transition: all 0.3s ease;
    box-shadow: 0 0 10px rgba(82, 20, 22, 0.08);
}

.modal-btn:hover {
    background: var(--accent-color);
    color: var(--bg-color);
    box-shadow: 0 0 15px rgba(82, 20, 22, 0.18);
    transform: translateY(-2px);
}

/* Contact Page */
.contact-section {
    flex: 1;
    width: min(100%, 1120px);
    margin: 0 auto;
    padding: 4rem 5%;
}

.contact-panel {
    background: var(--panel-bg);
    border: 3px double var(--frame-border);
    border-radius: 8px;
    padding: clamp(2rem, 4vw, 3.5rem);
    box-shadow: 0 16px 34px rgba(82, 20, 22, 0.12);
}

.contact-title {
    font-family: 'Playfair Display', serif;
    color: var(--accent-color);
    font-size: clamp(1.85rem, 3vw, 2.65rem);
    line-height: 1.15;
    margin-bottom: 1rem;
    max-width: 100%;
    text-wrap: balance;
}

.contact-text {
    font-size: 1.36rem;
    line-height: 1.7;
    margin-bottom: 2rem;
}

.contact-list {
    display: grid;
    gap: 1rem;
}

.contact-item {
    display: flex;
    justify-content: space-between;
    gap: 1.5rem;
    border-top: 1px solid rgba(100, 27, 31, 0.14);
    padding-top: 1rem;
}

.contact-label {
    font-family: 'Cinzel', serif;
    color: var(--accent-color);
    font-size: 1.12rem;
}

.contact-value {
    font-size: 1.12rem;
    text-align: right;
    line-height: 1.55;
}

.contact-value a {
    color: inherit;
    overflow-wrap: anywhere;
    text-decoration-color: rgba(100, 27, 31, 0.36);
}

@media (max-width: 720px) {
    .contact-title {
        white-space: normal;
    }

    .contact-item {
        align-items: flex-start;
        flex-direction: column;
        gap: 0.4rem;
    }

    .contact-value {
        text-align: left;
    }
}

/* Detail Pages */
.detail-page {
    width: min(100%, 1100px);
    margin: 0 auto;
    padding: 4rem 5%;
}

.compact-detail {
    width: min(100%, 860px);
}

.gallery-page {
    width: min(100%, 1560px);
    padding-left: 3%;
    padding-right: 3%;
}

.detail-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.detail-title {
    font-family: 'Playfair Display', serif;
    color: var(--accent-color);
    font-size: clamp(2.2rem, 5vw, 4rem);
    line-height: 1.12;
    margin-bottom: 0.75rem;
}

.detail-subtitle {
    font-family: 'Cinzel', serif;
    color: var(--secondary-accent);
    font-size: clamp(0.95rem, 2vw, 1.25rem);
    line-height: 1.5;
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-bottom: 1.5rem;
}

.event-feature,
.event-description,
.event-photos,
.gallery-page-panel,
.achievement-feature {
    background: var(--panel-bg);
    border: 3px double var(--frame-border);
    border-radius: 8px;
    box-shadow: 0 16px 34px rgba(82, 20, 22, 0.12);
}

.event-feature {
    padding: clamp(1rem, 3vw, 2rem);
    margin-bottom: 2rem;
}

.event-poster {
    display: block;
    width: min(100%, 620px);
    max-height: 900px;
    object-fit: contain;
    margin: 0 auto;
    border-radius: 6px;
}

.event-description,
.event-photos,
.gallery-page-panel {
    padding: clamp(1.5rem, 3vw, 2.5rem);
    margin-bottom: 2rem;
    overflow: hidden;
}

.gallery-page .gallery-frames {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
    gap: 1.25rem;
    height: auto;
    width: 100%;
}

.gallery-page .gallery-photo-frame {
    aspect-ratio: 4 / 3;
    min-height: 0;
    min-width: 0;
    width: 100%;
    padding: 0.5rem;
    box-sizing: border-box;
}

.gallery-page .gallery-photo-frame img {
    display: block;
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    background: rgba(255, 250, 244, 0.62);
}

.section-heading {
    font-family: 'Cinzel', serif;
    color: var(--accent-color);
    font-size: clamp(1.35rem, 3vw, 2rem);
    text-align: center;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    margin-bottom: 1.5rem;
}

.description-space {
    min-height: 160px;
    border: 1px dashed rgba(100, 27, 31, 0.22);
    border-radius: 6px;
    background: rgba(255, 250, 244, 0.42);
}

.event-photo-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.25rem;
}

.event-photo-grid img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    border-radius: 6px;
    border: 1px solid rgba(100, 27, 31, 0.14);
}

.achievement-feature {
    padding: clamp(1rem, 3vw, 2rem);
    text-align: center;
}

.achievement-feature img {
    display: block;
    width: 100%;
    max-height: 680px;
    object-fit: contain;
    border-radius: 6px;
    margin: 0 auto;
}

.achievement-feature figcaption {
    font-family: 'Cinzel', serif;
    color: var(--accent-color);
    font-size: 1rem;
    letter-spacing: 0.8px;
    margin-top: 1.25rem;
}

@media (max-width: 768px) {
    .detail-page {
        padding: 3rem 5%;
    }

    .event-photo-grid {
        grid-template-columns: 1fr;
    }
}

.event-feature-split {
    display: grid;
    grid-template-columns: minmax(220px, 0.72fr) minmax(0, 1.28fr);
    gap: clamp(1.5rem, 4vw, 3rem);
    align-items: center;
}

.event-feature-split .event-poster {
    width: min(100%, 360px);
    max-height: 560px;
}

.event-description-copy {
    font-size: clamp(1.05rem, 1.5vw, 1.24rem);
    line-height: 1.85;
    color: var(--text-color);
}

.event-description-copy .section-heading {
    text-align: left;
}

.event-description-copy p + p {
    margin-top: 1.25rem;
}

.course-panel,
.registration-panel {
    background: var(--panel-bg);
    border: 3px double var(--frame-border);
    border-radius: 8px;
    box-shadow: 0 16px 34px rgba(82, 20, 22, 0.12);
    padding: clamp(1.75rem, 4vw, 3rem);
}

.tabla-course {
    position: relative;
}

.teacher-profile {
    display: grid;
    gap: 1.4rem;
}

.teacher-line {
    font-size: 1.15rem;
    line-height: 1.7;
    color: var(--text-color);
}

.teacher-line span {
    display: inline-block;
    min-width: 98px;
    margin-right: 0.5rem;
    font-family: 'Cinzel', serif;
    color: var(--accent-color);
    letter-spacing: 0.8px;
}

.course-actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 2rem;
}

.register-student-trigger,
.submit-registration {
    font-family: 'Cinzel', serif;
    background: var(--accent-color);
    color: var(--bg-color);
    border: 1px solid var(--accent-color);
    border-radius: 4px;
    padding: 0.8rem 1.4rem;
    font-size: 0.95rem;
    letter-spacing: 1px;
    text-transform: uppercase;
    cursor: pointer;
    box-shadow: 0 10px 22px rgba(82, 20, 22, 0.16);
    transition: transform 0.25s ease, box-shadow 0.25s ease, background-color 0.25s ease;
}

.register-student-trigger:hover,
.register-student-trigger:focus-visible,
.submit-registration:hover,
.submit-registration:focus-visible {
    background: #7b2429;
    transform: translateY(-2px);
    box-shadow: 0 14px 26px rgba(82, 20, 22, 0.22);
}

.registration-panel {
    margin-top: 2rem;
}

.registration-panel[hidden] {
    display: none;
}

.registration-header {
    text-align: center;
    margin-bottom: 2rem;
}

.registration-header h2 {
    font-family: 'Playfair Display', serif;
    color: var(--accent-color);
    font-size: clamp(1.8rem, 4vw, 2.6rem);
    margin-bottom: 0.5rem;
}

.registration-header p {
    font-size: 1.05rem;
    line-height: 1.6;
    color: rgba(66, 20, 23, 0.84);
}

.registration-form {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.25rem 1.5rem;
}

.registration-form label {
    display: grid;
    gap: 0.55rem;
}

.registration-form label span {
    font-family: 'Cinzel', serif;
    color: var(--accent-color);
    font-size: 0.86rem;
    letter-spacing: 0.8px;
    text-transform: uppercase;
}

.registration-form input,
.registration-form textarea {
    width: 100%;
    border: 1px solid rgba(100, 27, 31, 0.24);
    border-radius: 6px;
    background: rgba(255, 250, 244, 0.72);
    color: var(--text-color);
    font: inherit;
    padding: 0.8rem 0.9rem;
    outline: none;
    transition: border-color 0.25s ease, box-shadow 0.25s ease, background-color 0.25s ease;
}

.registration-form input:focus,
.registration-form textarea:focus {
    border-color: var(--accent-color);
    background: rgba(255, 250, 244, 0.95);
    box-shadow: 0 0 0 3px rgba(100, 27, 31, 0.09);
}

.registration-form textarea {
    resize: vertical;
}

.wide-field,
.submit-registration {
    grid-column: 1 / -1;
}

.submit-registration {
    justify-self: end;
    min-width: 210px;
    margin-top: 0.5rem;
}

@media (max-width: 768px) {
    .event-feature-split,
    .registration-form {
        grid-template-columns: 1fr;
    }

    .event-description-copy .section-heading {
        text-align: center;
    }

    .course-actions,
    .submit-registration {
        justify-self: stretch;
        justify-content: stretch;
    }

    .register-student-trigger,
    .submit-registration {
        width: 100%;
    }
}

/* Admin Portal */
.admin-page {
    min-height: 100vh;
}

.admin-login-page,
.admin-portal {
    width: 100%;
    padding: clamp(2rem, 5vw, 4rem) 5%;
}

.admin-login-panel,
.admin-edit-card,
.admin-preview-panel,
.admin-toolbar {
    background: rgba(255, 250, 244, 0.82);
    border: 2px solid rgba(168, 121, 47, 0.34);
    border-radius: 8px;
    box-shadow: 0 16px 34px rgba(82, 20, 22, 0.12);
}

.admin-login-panel {
    width: min(100%, 520px);
    margin: 3rem auto;
    padding: clamp(2rem, 5vw, 3rem);
}

.admin-login-panel h1,
.admin-toolbar h1,
.admin-preview-heading h2,
.admin-edit-card h2 {
    font-family: 'Playfair Display', serif;
    color: var(--accent-color);
    line-height: 1.2;
}

.admin-login-panel h1 {
    font-size: clamp(2rem, 4vw, 3rem);
    margin-bottom: 0.75rem;
}

.admin-login-panel p {
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

.admin-login-form,
.admin-field-list,
.admin-field {
    display: grid;
    gap: 1rem;
}

.admin-login-form label,
.admin-field {
    color: var(--text-color);
}

.admin-login-form span,
.admin-field span,
.admin-eyebrow {
    font-family: 'Cinzel', serif;
    color: var(--accent-color);
    font-size: 0.82rem;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.admin-login-form input,
.admin-field input,
.admin-field textarea {
    width: 100%;
    border: 1px solid rgba(100, 27, 31, 0.24);
    border-radius: 6px;
    background: rgba(255, 250, 244, 0.78);
    color: var(--text-color);
    font: inherit;
    padding: 0.8rem 0.9rem;
    outline: none;
    transition: border-color 0.25s ease, box-shadow 0.25s ease, background-color 0.25s ease;
}

.admin-field textarea {
    resize: vertical;
}

.admin-login-form input:focus,
.admin-field input:focus,
.admin-field textarea:focus {
    border-color: var(--accent-color);
    background: rgba(255, 250, 244, 0.96);
    box-shadow: 0 0 0 3px rgba(100, 27, 31, 0.09);
}

.admin-primary-btn,
.admin-secondary-btn,
.admin-add-btn,
.admin-delete-btn {
    border-radius: 4px;
    cursor: pointer;
    font-family: 'Cinzel', serif;
    letter-spacing: 0.8px;
    text-transform: uppercase;
    transition: background-color 0.25s ease, color 0.25s ease, transform 0.25s ease, box-shadow 0.25s ease;
}

.admin-primary-btn {
    background: var(--accent-color);
    border: 1px solid var(--accent-color);
    color: var(--bg-color);
    padding: 0.85rem 1.35rem;
    box-shadow: 0 10px 20px rgba(82, 20, 22, 0.15);
}

.admin-secondary-btn,
.admin-add-btn {
    background: rgba(255, 250, 244, 0.72);
    border: 1px solid rgba(100, 27, 31, 0.3);
    color: var(--accent-color);
    padding: 0.75rem 1rem;
}

.admin-delete-btn {
    background: rgba(100, 27, 31, 0.08);
    border: 1px solid rgba(100, 27, 31, 0.22);
    color: var(--accent-color);
    padding: 0.55rem 0.8rem;
    font-size: 0.75rem;
}

.admin-home-gallery-btn {
    justify-self: start;
}

.admin-primary-btn:hover,
.admin-secondary-btn:hover,
.admin-add-btn:hover,
.admin-delete-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 18px rgba(82, 20, 22, 0.12);
}

.admin-toolbar {
    display: flex;
    justify-content: space-between;
    gap: 1.5rem;
    align-items: center;
    padding: clamp(1.25rem, 3vw, 2rem);
    margin-bottom: 1rem;
}

.admin-toolbar h1 {
    font-size: clamp(1.8rem, 3vw, 2.6rem);
}

.admin-toolbar-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 0.75rem;
}

.admin-status {
    min-height: 44px;
    margin-bottom: 1.5rem;
    padding: 0.8rem 1rem;
    border-radius: 6px;
    border: 1px solid rgba(100, 27, 31, 0.16);
    background: rgba(255, 250, 244, 0.68);
    color: var(--text-color);
    line-height: 1.5;
}

.admin-status[data-tone="warning"] {
    border-color: rgba(168, 121, 47, 0.45);
    background: rgba(255, 244, 220, 0.78);
}

.admin-status[data-tone="success"] {
    border-color: rgba(70, 122, 80, 0.34);
    background: rgba(236, 248, 238, 0.76);
}

.admin-status[data-tone="error"] {
    border-color: rgba(143, 31, 40, 0.38);
    background: rgba(255, 232, 234, 0.78);
    color: #8f1f28;
}

.admin-error {
    min-height: 1.3rem;
    color: #8f1f28;
    margin-bottom: 0;
}

.admin-edit-layout {
    display: grid;
    grid-template-columns: minmax(320px, 0.78fr) minmax(0, 1.22fr);
    gap: clamp(1.25rem, 3vw, 2rem);
    align-items: start;
}

.admin-editor-panel,
.admin-field-list {
    display: grid;
    gap: 1.25rem;
}

.admin-edit-card {
    padding: clamp(1.2rem, 2.5vw, 1.8rem);
}

.admin-card-header,
.admin-item-header {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    align-items: center;
    margin-bottom: 1rem;
}

.admin-edit-card h2 {
    font-size: clamp(1.35rem, 2.4vw, 1.8rem);
}

.admin-edit-item {
    border: 1px solid rgba(100, 27, 31, 0.16);
    border-radius: 8px;
    background: rgba(255, 250, 244, 0.58);
    padding: 1rem;
    display: grid;
    gap: 1rem;
}

.admin-item-header {
    margin-bottom: 0;
}

.admin-item-header h3 {
    font-family: 'Cinzel', serif;
    color: var(--secondary-accent);
    font-size: 0.98rem;
    letter-spacing: 0.8px;
}

.admin-event-photos {
    border-top: 1px solid rgba(100, 27, 31, 0.14);
    display: grid;
    gap: 1rem;
    padding-top: 1rem;
}

.admin-event-photos-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.admin-event-photos h4,
.admin-photo-edit-item h5 {
    font-family: 'Cinzel', serif;
    color: var(--accent-color);
    letter-spacing: 0.8px;
    text-transform: uppercase;
}

.admin-event-photos h4 {
    font-size: 0.92rem;
}

.admin-photo-frame-list {
    display: grid;
    gap: 1rem;
}

.admin-photo-edit-item {
    border: 1px solid rgba(168, 121, 47, 0.24);
    border-radius: 8px;
    background: rgba(255, 250, 244, 0.5);
    display: grid;
    gap: 1rem;
    padding: 1rem;
}

.admin-photo-edit-item h5 {
    font-size: 0.78rem;
}

.admin-empty-note {
    border: 1px dashed rgba(168, 121, 47, 0.34);
    border-radius: 6px;
    color: rgba(66, 20, 23, 0.66);
    font-size: 0.95rem;
    line-height: 1.5;
    margin: 0;
    padding: 0.9rem;
}

.admin-file-field input {
    padding: 0.65rem;
}

.admin-image-preview {
    min-height: 120px;
    border: 1px dashed rgba(168, 121, 47, 0.38);
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(66, 20, 23, 0.6);
    background: rgba(255, 250, 244, 0.54);
    overflow: hidden;
}

.admin-image-preview img {
    width: 100%;
    max-height: 220px;
    object-fit: contain;
}

.admin-preview-panel {
    padding: clamp(1rem, 2vw, 1.5rem);
    position: sticky;
    top: 120px;
    max-height: calc(100vh - 150px);
    overflow: auto;
}

.admin-preview-heading {
    margin-bottom: 1rem;
}

.admin-preview-site {
    border: 1px solid rgba(100, 27, 31, 0.14);
    border-radius: 8px;
    background:
        linear-gradient(rgba(247, 240, 233, 0.62), rgba(247, 240, 233, 0.62)),
        url("site-background.png");
    background-position: center;
    background-size: cover;
    padding: 1rem;
    overflow: hidden;
}

.admin-preview-site .home-layout {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr) minmax(0, 1fr);
    gap: 1rem;
    min-height: 520px;
    margin-bottom: 1rem;
    padding: 0;
    overflow: hidden;
    width: 100%;
}

.admin-preview-site .home-column {
    min-height: 420px;
    height: 420px;
    padding: 1.2rem;
    min-width: 0;
}

.admin-preview-site .center-column {
    min-width: 0;
    max-width: 100%;
    overflow: hidden;
}

.admin-preview-site .firm-name {
    font-size: clamp(1.8rem, 3vw, 2.9rem);
    max-width: 100%;
    overflow-wrap: anywhere;
}

.admin-preview-site .firm-main-title {
    white-space: normal;
    overflow-wrap: anywhere;
    word-break: normal;
}

.admin-preview-site .subtitle {
    font-size: clamp(1.15rem, 1.9vw, 1.65rem);
    white-space: normal;
}

.admin-preview-site .achievements-section,
.admin-preview-site .news-section {
    padding: 2rem 0;
    margin-top: 1rem;
}

.admin-preview-site .news-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

.admin-preview-site .announcement-item p {
    font-size: 1.25rem;
}

.admin-preview-site .announcement-arrow {
    width: 0.62rem;
    height: 0.62rem;
    margin-top: 0.5rem;
}

.admin-preview-site .achievements-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

@media (max-width: 1200px) {
    .admin-edit-layout {
        grid-template-columns: 1fr;
    }

    .admin-preview-panel {
        position: static;
        max-height: none;
    }
}

@media (max-width: 768px) {
    .admin-toolbar {
        align-items: stretch;
        flex-direction: column;
    }

    .admin-toolbar-actions,
    .admin-primary-btn,
    .admin-secondary-btn {
        width: 100%;
    }

    .admin-toolbar-actions button {
        flex: 1 1 100%;
    }

    .admin-preview-site .home-layout,
    .admin-preview-site .news-grid,
    .admin-preview-site .achievements-grid {
        grid-template-columns: 1fr;
    }
}

/* ========================================
   Desktop layout normalization
   Designed to match the preferred 75% view
   while browser zoom remains at 100%
   ======================================== */
@media (min-width: 1025px) {

    /* Navigation */
    .navbar {
        min-height: 88px;
        padding: 0.75rem 4%;
    }

    .circular-logo {
        width: 76px;
        height: 76px;
    }

    .nav-links {
        gap: 1rem;
    }

    .nav-item {
        font-size: 1rem;
        min-width: 120px;
        padding: 0.55rem 1rem;
        letter-spacing: 1.5px;
    }

    /* Main page spacing */
    .main-container {
        padding: 2rem 5%;
    }

    .home-layout {
        grid-template-columns:
            minmax(280px, 1.25fr)
            minmax(0, 2.4fr)
            minmax(280px, 1.25fr);
        gap: 4rem;
        padding: 0;
    }

    /* Prevent center title from squeezing side panels */
    .center-column {
        min-width: 0;
    }

    /* Side frames */
    .home-column {
        padding: 1.5rem 1.25rem;
    }

    .column-title {
        font-size: 1.45rem;
        margin-bottom: 1.5rem;
    }

    .announcement-list {
        gap: 1.5rem;
    }

    .announcement-item {
        gap: 0.8rem;
    }

    .announcement-item p {
        font-size: 1.25rem;
        line-height: 1.55;
    }

    /* Main academy name */
    .firm-name {
        font-size: clamp(3.6rem, 5vw, 5.6rem);
    }

    .subtitle {
        font-size: clamp(2rem, 2.8vw, 3.1rem);
    }

    /* Gallery */
    .home-gallery-frames .gallery-photo-frame {
        flex-basis: clamp(190px, 30vh, 270px);
        min-height: 190px;
    }

    .gallery-view-all {
        font-size: 0.9rem;
        padding: 0.6rem 1.1rem;
    }
}

/* Admin preview must fit inside the editor panel, not the full desktop viewport. */
body.admin-page .admin-preview-site {
    contain: layout paint;
    overflow-x: clip;
}

body.admin-page .admin-preview-site .home-layout {
    display: grid;
    grid-template-columns: minmax(180px, 0.95fr) minmax(150px, 0.72fr) minmax(180px, 0.95fr) !important;
    gap: clamp(0.65rem, 1.1vw, 1rem) !important;
    align-items: center;
    min-height: 440px;
    overflow-x: clip;
}

body.admin-page .admin-preview-site .home-column,
body.admin-page .admin-preview-site .center-column {
    min-width: 0;
    max-width: 100%;
}

body.admin-page .admin-preview-site .home-column {
    height: 380px;
    min-height: 380px;
    padding: 1rem;
    overflow: hidden;
}

body.admin-page .admin-preview-site .center-column {
    padding: 0 0.25rem;
}

body.admin-page .admin-preview-site .firm-name {
    display: block;
    width: 100%;
    max-width: 100%;
    font-size: clamp(1.25rem, 1.75vw, 2rem) !important;
    line-height: 1.08;
    overflow-wrap: anywhere;
    word-break: break-word;
}

body.admin-page .admin-preview-site .firm-main-title,
body.admin-page .admin-preview-site .subtitle {
    display: block;
    max-width: 100%;
    white-space: normal !important;
    overflow-wrap: anywhere;
    word-break: break-word;
}

body.admin-page .admin-preview-site .subtitle {
    font-size: clamp(1rem, 1.35vw, 1.45rem) !important;
}

body.admin-page .admin-preview-site .column-title {
    font-size: clamp(1rem, 1.35vw, 1.35rem);
    overflow-wrap: anywhere;
}

@media (max-width: 1400px) {
    body.admin-page .admin-preview-site .home-layout {
        grid-template-columns: 1fr !important;
        min-height: 0;
        align-items: stretch;
    }

    body.admin-page .admin-preview-site .center-column {
        order: -1;
    }

    body.admin-page .admin-preview-site .home-column {
        height: auto;
        min-height: 260px;
        max-height: 360px;
    }
}
