:root {
    /* Neutral scale (softened neutrals) - light -> dark */
    --neutral-0: #f6f5f3;
    --neutral-1: #efeeec;
    --neutral-2: #e6e4e1;
    --neutral-3: #d7d3cf;
    --neutral-4: #bfb9b4;
    --neutral-5: #9d958f;
    --neutral-6: #7b7370;
    --neutral-7: #5d5551;
    --neutral-8: #3f3835;
    --neutral-9: #26221f;

    /* Palette - 60/30/10 rule
       - Primary neutral (60%): background
       - Secondary neutral (30%): surfaces, cards, nav
       - Accent (10%): buttons, links, highlights */
    --bg-color: var(--neutral-0);
    --surface-color: var(--neutral-2);
    --text-color: var(--neutral-9);
    --muted-text: var(--neutral-6);

    /* Subtle accent (tested for sufficient contrast on light backgrounds) */
    --accent-color: #0b7285;
    --accent-foreground: #ffffff;

    /* Slightly softened nav background using surface color */
    --nav-bg: rgba(255, 255, 255, 0.9);

    --section-spacing: 1rem;
}

*, *::before, *::after {
    box-sizing: border-box;
}

html {
    font-family: "Roboto", sans-serif;
    scroll-behavior: smooth;
}

body {
    margin: 0;
    padding: 7rem 0 0;
    min-height: 100vh;
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    align-items: center;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

ul, ol {
    margin: 0;
    padding: 0;
    list-style: none;
}

section {
    scroll-margin-top: 7rem;
}

a {
    color: var(--accent-color);
    text-decoration: none;
}

a:hover,
a:focus {
    text-decoration: underline;
    outline: none;
}

.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.15rem 2rem;
    min-height: 7rem;
    background: var(--nav-bg);
    border-bottom: 1px solid var(--neutral-2);
    box-shadow: 0 6px 20px rgba(30, 30, 30, 0.06);
    z-index: 10;
    color: var(--neutral-9);
}

.navbar .logo {
    display: flex;
    align-items: center;
    flex-shrink: 0;
    margin: 0;
    padding: 0;
    height: 100%;
}

.logo img {
    height: calc(100% - 0.1rem);
    width: auto;
    max-height: 6.8rem;
    display: block;
}

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

.nav-links a {
    font-size: 1.25rem;
    padding: 0.5rem 0.75rem;
    transition: color 0.2s ease-in-out;
}

.language-switcher {
    display: inline-flex;
    gap: 0.5rem;
    align-items: center;
}

.language-switcher button {
    border: 1px solid var(--neutral-4);
    background: var(--neutral-1);
    color: var(--neutral-9);
    padding: 0.35rem 0.65rem;
    border-radius: 999px;
    cursor: pointer;
    font-size: 0.95rem;
    transition: background 0.2s ease, color 0.2s ease;
}

.language-switcher button.active,
.language-switcher button:hover {
    background: var(--accent-color);
    color: var(--accent-foreground);
}

.page-shell {
    width: min(90%, 1200px);
    padding: 0 1rem 3rem;
    flex-direction: column;
    align-items: center;
}

.page-section {
    width: 90%;
    flex-direction: column;
    justify-content: center;
    text-align: center;
    margin-left: auto;
    margin-right: auto;
    padding: 0 1rem;
    max-width: 1200px;
}

.page-section h2 {
    margin-bottom: 1rem;
    font-size: clamp(1.6rem, 3.2vw, 2.6rem);
}

.page-section h3 {
    font-size: clamp(1.2rem, 2.4vw, 1.6rem);
}

#services h3 {
    font-size: clamp(1.4rem, 2.8vw, 2rem);
}

.page-section p {
    font-size: clamp(1rem, 1.8vw, 1.25rem);
}

.hero {
    width: 100%;
    min-height: calc(100vh - 7rem);
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--neutral-0);
    background-image: url("./images/ur_background.png");
    background-size: cover;
    background-position: center;
    position: relative;
    padding: 2rem 1rem;
}

.hero::before {
    content: "";
    position: absolute;
    inset: 0;
    /* use softened dark neutral overlay so headline remains readable */
    background: linear-gradient(rgba(38,34,31,0.36), rgba(38,34,31,0.36));
    z-index: 0;
}

.hero > * {
    position: relative;
    z-index: 1;
}

.hero h1 {
    font-size: clamp(2.2rem, 7vw, 5.5rem);
    margin: 0.25rem 0;
}

.hero p {
    font-size: clamp(1.1rem, 2.5vw, 1.5rem);
    max-width: 60ch;
    margin: 0 auto;
    margin-top: 0.75rem;
}

.card-list {
    display: inline-flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 2rem;
    width: 100%;
}

.card-item {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 0.75rem;
    padding: 1.25rem;
    max-width: 30rem;
    font-size: 2rem;
}

.card-item img {
    /* Constrain images to consistent visual size but preserve original aspect ratio */
    max-width: 25rem;
    max-height: 18rem;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 0.5rem;
    background-color: var(--surface-color);
    padding: 0.25rem;
}

.card-item a {
    font-weight: 700;
}

.card-link {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 0.75rem;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card-link:hover {
    transform: translateY(-0.5rem);
}

/* CTA / button styles following 60-30-10: accent used sparingly */
.btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.6rem 1rem;
    border-radius: 0.5rem;
    background: var(--accent-color);
    color: var(--accent-foreground);
    text-decoration: none;
    font-weight: 600;
}

.btn-primary:hover,
.btn-primary:focus {
    background: color-mix(in srgb, var(--accent-color) 90%, black 10%);
    box-shadow: 0 6px 20px rgba(11,114,133,0.12);
    outline: none;
}

/* Media grid and cards for video/file placeholders */
.media-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.25rem;
    width: 100%;
    margin-top: 1rem;
}

.media-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 1rem;
    width: 100%;
}

.media-preview {
    width: 100%;
    height: 320px; /* adjust as needed for proportion */
    display: flex;
    justify-content: center;
    overflow: hidden;
    border-radius: 0.75rem;
    background: var(--neutral-1);
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
    padding: 1rem;
}

.media-preview iframe {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top;
}

.media-preview img {
    width: 100%;
    height: auto;
    object-position: top;
}

.muted {
    color: var(--muted-text);
    margin: 0;
}

/* When muted text appears on the hero, use the same color as the hero heading */
.hero .muted {
    color: var(--neutral-0);
}

/* Assessment form */
.assessment-form {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 0.75rem;
    align-items: start;
    width: min(90%, 920px);
    margin: 0 auto;
}

.assessment-form label {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.topic-list {
    list-style: disc;
    padding-left: 1.25rem;
    margin: 0.5rem auto 0;
    max-width: 60ch;
    text-align: left;
}

.service-card {
    cursor: pointer;
}

.service-card img {
    cursor: pointer;
}

.service-details {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    text-align: center;
    padding: 1rem 0;
    width: 100%;
    min-height: 100%;
}

.service-details h3 {
    margin: 0;
    font-size: 1.75rem;
}

.service-details p {
    margin: 0;
    font-size: 1rem;
}

.contact-details {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 0.25rem;
}

.contact-details p {
    font-size: 1rem;
    margin: 1rem;
}

.contact-form {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    width: min(100%, 32rem);
    gap: 0.75rem;
    margin: 0 auto;
}

.contact-form label {
    width: 90%;
}

.contact-form input,
.contact-form textarea,
.contact-form select {
    width: 90%;
    max-width: 32rem;
    text-align: center;
    padding: 0.75rem;
}

.contact-form input,
.contact-form textarea,
.contact-form select {
    background: var(--surface-color);
    color: var(--text-color);
    border-radius: 0.375rem;
}

.contact-form input:focus,
.contact-form textarea:focus,
.contact-form select:focus {
    outline: none;
    box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent-color) 10%, transparent 90%);
    border-color: var(--accent-color);
}

.contact-form textarea {
    resize: vertical;
    min-height: 8rem;
}

.form-status {
    width: 100%;
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    margin-top: 0.25rem;
    font-size: 0.95rem;
    display: none;
}

.form-status.success {
    display: block;
    background: color-mix(in srgb, var(--accent-color) 10%, transparent 90%);
    border: 1px solid var(--accent-color);
    color: var(--accent-color);
}

.form-status.error {
    display: block;
    background: color-mix(in srgb, #ff4f4f 10%, transparent 90%);
    border: 1px solid #ff4f4f;
    color: #9b2b2b;
}

 .site-footer {
    width: 100%;
    text-align: center;
    padding: 2rem 1rem 3rem;
} 

.site-footer .compliance {
    padding: 0;
}

@media only screen and (max-width: 768px) {
    .navbar {
        padding: 0.15rem 1rem;
        min-height: 6rem;
    }

    .logo img {
        max-height: 5.5rem;
    }

    .nav-links a {
        font-size: clamp(0.9rem, 2.4vw, 1rem);
        padding: 0.4rem 0.55rem;
    }

    .hero {
        min-height: calc(60vh - 4rem);
    }

    .hero h1 {
        font-size: clamp(2rem, 8vw, 3.5rem);
        padding: 0.5rem 1rem;
    }

    .page-section h2 {
        font-size: clamp(1.35rem, 5vw, 1.8rem);
        margin: auto 2rem;
    }

    .page-section h3 {
        font-size: clamp(1.05rem, 3.5vw, 1.35rem);
        margin: auto 2rem;
    }

    .page-section p,
    .page-section span {
        font-size: clamp(0.95rem, 2.8vw, 1.05rem);
        margin: auto 2rem;
    }

    .contact-form input,
    .contact-form textarea,
    .contact-form input[type="submit"] {
        font-size: clamp(0.95rem, 2.6vw, 1rem);
    }

    .card-list {
        flex-direction: column;
        align-content: center;
    }

    .card-item img {
        height: 14rem;
        width: 14rem;
    }

    .page-section table {
        width: 100%;
        padding: 0 0.5rem;
        font-size: small;
    }

    .page-section ul,
    .page-section ol {
        padding-left: 1.25rem; /* prevents edge hugging */
        text-align: center;      /* lists should never be centered */
    }
   
    .page-section p {
        text-align: center;
        padding-left: 0.25rem;
        padding-right: 0.25rem;
        line-height: 1.55;
        font-size: small;
    }

    .site-footer {
        text-align: center;
        padding-left: 0.25rem;
        padding-right: 0.25rem;
        line-height: 1.55;
        font-size: small;
    } 
}