/* ============================================
   MARZ LIMITED - Main Stylesheet
   Mobile-first | Light/Dark mode via CSS vars
   ============================================ */

/* --- Custom Properties (Light Mode) --- */
:root {
    --primary: #D81E3E;
    --primary-dark: #b01832;
    --primary-light: rgba(216, 30, 62, 0.1);

    --bg: #ffffff;
    --bg-alt: #f7f7f9;
    --bg-dark-section: #1a1a2e;
    --text: #232323;
    --text-muted: #5a5a6e;
    --text-light: #ffffff;
    --card-bg: #ffffff;
    --card-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
    --card-shadow-hover: 0 8px 28px rgba(0, 0, 0, 0.1);
    --nav-bg: rgba(255, 255, 255, 0.97);
    --border: #e8e8ec;
    --footer-bg: #16161a;
    --cta-bg: linear-gradient(135deg, #D81E3E 0%, #8b1529 100%);

    --font-heading: 'Lato', sans-serif;
    --font-body: 'Open Sans', sans-serif;

    --radius: 10px;
    --transition: 0.3s ease;
}

/* --- Dark Mode Overrides --- */
[data-theme="dark"] {
    --bg: #12121a;
    --bg-alt: #1a1a28;
    --bg-dark-section: #0e0e16;
    --text: #e8e8ec;
    --text-muted: #9a9ab0;
    --card-bg: #1e1e30;
    --card-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
    --card-shadow-hover: 0 8px 28px rgba(0, 0, 0, 0.5);
    --nav-bg: rgba(18, 18, 26, 0.97);
    --border: #2a2a3e;
    --footer-bg: #0a0a10;
}

/* --- Reset & Base --- */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

body {
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.7;
    color: var(--text);
    background-color: var(--bg);
    transition: background-color var(--transition), color var(--transition);
    -webkit-font-smoothing: antialiased;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

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

a:hover, a:focus {
    color: var(--primary-dark);
}

ul {
    list-style: none;
}

/* --- Accessibility --- */
.skip-link {
    position: absolute;
    top: -100%;
    left: 16px;
    z-index: 9999;
    padding: 12px 24px;
    background: var(--primary);
    color: #fff;
    border-radius: 0 0 var(--radius) var(--radius);
    font-weight: 600;
    transition: top 0.2s;
}

.skip-link:focus {
    top: 0;
    color: #fff;
}

/* --- Layout Utilities --- */
.container {
    width: 100%;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 20px;
    padding-right: 20px;
}

.section {
    padding: 80px 0;
}

.section--alt {
    background-color: var(--bg-alt);
}

.section--dark {
    background-color: var(--bg-dark-section);
    color: var(--text-light);
}

.section__title {
    font-family: var(--font-heading);
    font-size: 2rem;
    font-weight: 900;
    text-align: center;
    letter-spacing: 1px;
    margin-bottom: 16px;
    color: var(--text);
}

.section__title--light {
    color: #fff;
}

.section__subtitle {
    text-align: center;
    color: var(--text-muted);
    font-size: 1.05rem;
    max-width: 640px;
    margin: 0 auto 48px;
}

/* --- Grid --- */
.grid {
    display: grid;
    gap: 24px;
}

.grid--3 {
    grid-template-columns: 1fr;
}

.grid--4 {
    grid-template-columns: 1fr;
}

@media (min-width: 600px) {
    .grid--3, .grid--4 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 992px) {
    .grid--3 {
        grid-template-columns: repeat(3, 1fr);
    }
    .grid--4 {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* --- Navigation --- */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: var(--nav-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
    transition: background-color var(--transition), border-color var(--transition);
}

.nav__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
}

.nav__logo img {
    height: 32px;
    width: auto;
}

.nav__toggle {
    display: flex;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
}

.nav__toggle-bar {
    width: 24px;
    height: 2px;
    background: var(--text);
    transition: transform var(--transition), opacity var(--transition);
}

.nav__toggle[aria-expanded="true"] .nav__toggle-bar:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.nav__toggle[aria-expanded="true"] .nav__toggle-bar:nth-child(2) {
    opacity: 0;
}

.nav__toggle[aria-expanded="true"] .nav__toggle-bar:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

.nav__menu {
    display: none;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    background: var(--nav-bg);
    border-bottom: 1px solid var(--border);
    padding: 16px 20px;
}

.nav__menu.is-open {
    display: block;
}

.nav__list {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.nav__list a {
    display: block;
    padding: 10px 12px;
    color: var(--text);
    font-weight: 600;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-radius: 6px;
    transition: background-color var(--transition), color var(--transition);
}

.nav__list a:hover, .nav__list a:focus {
    background: var(--primary-light);
    color: var(--primary);
}

.nav__cta {
    background: var(--primary) !important;
    color: #fff !important;
    text-align: center;
}

.nav__cta:hover, .nav__cta:focus {
    background: var(--primary-dark) !important;
    color: #fff !important;
}

/* Theme Toggle */
.theme-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    border: 1px solid var(--border);
    background: transparent;
    color: var(--text);
    cursor: pointer;
    transition: background-color var(--transition), color var(--transition);
}

.theme-toggle:hover {
    background: var(--primary-light);
    color: var(--primary);
}

[data-theme="light"] .icon-moon { display: none; }
[data-theme="dark"] .icon-sun { display: none; }

@media (min-width: 768px) {
    .nav__toggle { display: none; }

    .nav__menu {
        display: block;
        position: static;
        background: transparent;
        border: none;
        padding: 0;
    }

    .nav__list {
        flex-direction: row;
        gap: 8px;
    }

    .nav__list a {
        padding: 8px 14px;
    }
}

/* --- Hero --- */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
    background-image: url('/images/hero-bg.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    padding: 100px 0 80px;
}

.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(8, 8, 18, 0.62);
    z-index: 1;
}

[data-theme="dark"] .hero::before {
    background: rgba(4, 4, 10, 0.7);
}

.hero__content {
    position: relative;
    z-index: 2;
}

.hero__title {
    font-family: var(--font-heading);
    font-size: clamp(3rem, 10vw, 5.5rem);
    font-weight: 900;
    letter-spacing: 12px;
    color: #fff;
    margin-bottom: 16px;
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.5);
}

.hero__subtitle {
    font-family: var(--font-heading);
    font-size: clamp(1.1rem, 3vw, 1.5rem);
    color: #fff;
    margin-bottom: 20px;
    text-shadow: 0 1px 8px rgba(0, 0, 0, 0.7);
}

.hero__desc {
    max-width: 600px;
    margin: 0 auto 36px;
    color: rgba(255, 255, 255, 0.92);
    font-size: 1rem;
    line-height: 1.7;
    text-shadow: 0 1px 6px rgba(0, 0, 0, 0.8);
}

.hero__actions {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

/* --- Buttons --- */
.btn {
    display: inline-block;
    padding: 12px 28px;
    font-family: var(--font-heading);
    font-size: 0.9rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-radius: 6px;
    border: 2px solid transparent;
    cursor: pointer;
    transition: all var(--transition);
}

.btn--primary {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}

.btn--primary:hover, .btn--primary:focus {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(216, 30, 62, 0.3);
}

.btn--outline {
    background: transparent;
    color: #fff;
    border-color: rgba(255, 255, 255, 0.5);
}

.btn--outline:hover, .btn--outline:focus {
    border-color: #fff;
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
}

.btn--lg {
    padding: 16px 36px;
    font-size: 1rem;
}

.btn--sm {
    padding: 8px 18px;
    font-size: 0.8rem;
}

/* --- Cards (Feature / Service) --- */
.card {
    background: var(--card-bg);
    border-radius: var(--radius);
    box-shadow: var(--card-shadow);
    padding: 32px 24px;
    transition: transform var(--transition), box-shadow var(--transition), background-color var(--transition);
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: var(--card-shadow-hover);
}

.card__icon {
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--primary-light);
    color: var(--primary);
    border-radius: 12px;
    margin-bottom: 20px;
}

.card__title {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--text);
}

.card__text {
    font-size: 0.92rem;
    color: var(--text-muted);
    line-height: 1.65;
}

/* --- About Section --- */
.about__grid {
    display: grid;
    gap: 40px;
    max-width: 900px;
    margin: 0 auto;
}

@media (min-width: 768px) {
    .about__grid {
        grid-template-columns: 1.5fr 1fr;
        align-items: start;
    }
}

.about__text p {
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 20px;
    font-size: 1rem;
}

.about__vision {
    background: rgba(255, 255, 255, 0.06);
    border-left: 3px solid var(--primary);
    padding: 28px;
    border-radius: 0 var(--radius) var(--radius) 0;
}

.about__vision h3 {
    font-family: var(--font-heading);
    font-size: 1.2rem;
    color: #fff;
    margin-bottom: 12px;
}

.about__vision p {
    color: rgba(255, 255, 255, 0.75);
    font-size: 0.95rem;
}

/* --- CTA Banner (IconMuse) --- */
.cta-banner {
    background: var(--cta-bg);
    padding: 60px 0;
}

.cta-banner__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 32px;
    flex-wrap: wrap;
}

.cta-banner__text h2 {
    font-family: var(--font-heading);
    font-size: 1.6rem;
    color: #fff;
    margin-bottom: 8px;
}

.cta-banner__text p {
    color: rgba(255, 255, 255, 0.85);
    max-width: 540px;
    font-size: 1rem;
}

@media (max-width: 767px) {
    .cta-banner__inner {
        flex-direction: column;
        text-align: center;
    }
}

/* --- Portfolio Cards --- */
.card--project {
    padding: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.card--project img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    background: var(--bg-alt);
}

.card__body {
    padding: 24px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.card__links {
    margin-top: auto;
    padding-top: 16px;
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.card__links a {
    display: inline-block;
    padding: 8px 14px;
    background: var(--primary);
    color: #fff;
    font-size: 0.8rem;
    font-weight: 600;
    border-radius: 5px;
    transition: background-color var(--transition);
}

.card__links a:hover, .card__links a:focus {
    background: var(--primary-dark);
    color: #fff;
}

/* --- Testimonials (Low Profile) --- */
.section--testimonials {
    padding: 60px 0;
}

.testimonial-quote {
    max-width: 700px;
    margin: 0 auto;
    text-align: center;
}

.testimonial-quote p {
    font-size: 1.2rem;
    font-style: italic;
    color: var(--text-muted);
    line-height: 1.8;
    position: relative;
    padding: 0 40px;
}

.testimonial-quote p::before,
.testimonial-quote p::after {
    content: '\201C';
    font-size: 3rem;
    color: var(--primary);
    opacity: 0.3;
    position: absolute;
    top: -10px;
}

.testimonial-quote p::before { left: 0; }
.testimonial-quote p::after { content: '\201D'; right: 0; }

/* --- Contact Section --- */
.contact__inner {
    text-align: center;
    max-width: 640px;
}

.contact__text {
    color: rgba(255, 255, 255, 0.75);
    margin-bottom: 32px;
    font-size: 1.05rem;
}

.contact__actions {
    margin-bottom: 32px;
}

.contact__social a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    transition: background-color var(--transition), transform var(--transition);
}

.contact__social a:hover {
    background: var(--primary);
    transform: scale(1.1);
}

/* --- Footer --- */
.footer {
    background: var(--footer-bg);
    color: rgba(255, 255, 255, 0.6);
    padding: 48px 0;
    text-align: center;
}

.footer__inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 24px;
}

.footer__logo {
    height: 28px;
    width: auto;
    opacity: 0.9;
}

.footer__links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px 24px;
}

.footer__links a {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.85rem;
    transition: color var(--transition);
}

.footer__links a:hover {
    color: #fff;
}

.footer__copy {
    font-size: 0.8rem;
    opacity: 0.7;
}

/* --- Cookie Banner --- */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 9999;
    background: var(--bg-dark-section);
    color: #fff;
    padding: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.3);
}

.cookie-banner__inner {
    max-width: 800px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
}

.cookie-banner__inner p {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.8);
    flex: 1;
    min-width: 260px;
}

.cookie-banner__inner a {
    color: var(--primary);
    text-decoration: underline;
}

.cookie-banner__actions {
    display: flex;
    gap: 10px;
}

@media (max-width: 600px) {
    .cookie-banner__inner {
        flex-direction: column;
        text-align: center;
    }
}

/* --- Scroll Animations (subtle fade-in) --- */
.fade-in {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* --- Responsive Adjustments --- */
@media (max-width: 767px) {
    .section {
        padding: 56px 0;
    }

    .section__title {
        font-size: 1.6rem;
    }

    .hero {
        min-height: 90vh;
        padding: 80px 0 60px;
    }

    .hero__title {
        letter-spacing: 6px;
    }

    .card {
        padding: 24px 20px;
    }

    .cta-banner {
        padding: 40px 0;
    }

    .cta-banner__text h2 {
        font-size: 1.3rem;
    }
}

/* --- Print Styles --- */
@media print {
    .nav, .cookie-banner, .theme-toggle, .hero__actions {
        display: none !important;
    }

    body {
        color: #000;
        background: #fff;
    }

    .section--dark, .hero {
        background: #fff;
        color: #000;
    }
}
