/* ========================================
   KARAKAYA METAL — Design System (Industrial Precision)
   ======================================== */

/* --- Google Fonts --- */
@import url('https://fonts.googleapis.com/css2?family=Work+Sans:wght@400;500;600;700;800;900&family=Manrope:wght@400;500;600;700&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:wght,FILL@100..700,0..1&display=swap');

/* --- CSS Custom Properties --- */
:root {
    --primary: #003f87;
    --primary-container: #0056b3;
    --on-primary: #ffffff;
    --on-primary-container: #bbd0ff;
    --secondary: #006398;
    --secondary-container: #00a9fd;
    --on-secondary: #ffffff;
    --tertiary: #414141;
    --tertiary-container: #595858;
    --on-tertiary: #ffffff;
    --surface: #f8f9fa;
    --surface-container: #edeeef;
    --surface-container-low: #f3f4f5;
    --surface-container-lowest: #ffffff;
    --surface-container-high: #e7e8e9;
    --surface-container-highest: #e1e3e4;
    --on-surface: #191c1d;
    --on-surface-variant: #424752;
    --outline: #727784;
    --outline-variant: #c2c6d4;
    --inverse-surface: #2e3132;
    --inverse-on-surface: #f0f1f2;
    --error: #ba1a1a;
    --on-error: #ffffff;
    --background: #f8f9fa;
    --on-background: #191c1d;

    --font-headline: 'Work Sans', sans-serif;
    --font-body: 'Manrope', sans-serif;

    --rounded-sm: 0.125rem;
    --rounded: 0.25rem;
    --rounded-md: 0.375rem;
    --rounded-lg: 0.5rem;
    --rounded-xl: 0.75rem;

    --base: 8px;
    --gutter: 24px;
    --section-padding: 80px;
    --container-max: 1280px;
    --shadow-card: 0px 4px 20px rgba(0, 86, 179, 0.08);
}

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

html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; }

body {
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.6;
    color: var(--on-surface);
    background: var(--background);
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }

.material-symbols-outlined {
    font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 24;
    vertical-align: middle;
}

/* --- Typography --- */
.headline-xl { font-family: var(--font-headline); font-size: 48px; font-weight: 700; line-height: 1.1; letter-spacing: -0.02em; }
.headline-lg { font-family: var(--font-headline); font-size: 32px; font-weight: 600; line-height: 1.2; }
.headline-md { font-family: var(--font-headline); font-size: 24px; font-weight: 600; line-height: 1.3; }
.body-lg { font-family: var(--font-body); font-size: 18px; font-weight: 400; line-height: 1.6; }
.body-md { font-family: var(--font-body); font-size: 16px; font-weight: 400; line-height: 1.6; }
.label-bold { font-family: var(--font-headline); font-size: 14px; font-weight: 700; line-height: 1; letter-spacing: 0.05em; }
.label-sm { font-family: var(--font-headline); font-size: 12px; font-weight: 500; line-height: 1; }

/* --- Layout --- */
.container { max-width: var(--container-max); margin: 0 auto; padding: 0 24px; }
@media (min-width: 768px) { .container { padding: 0 48px; } }

.section { padding: var(--section-padding) 0; }

/* --- Grid --- */
.grid-3 { display: grid; grid-template-columns: 1fr; gap: var(--gutter); }
@media (min-width: 768px) { .grid-3 { grid-template-columns: repeat(3, 1fr); } }

.grid-12 { display: grid; grid-template-columns: 1fr; gap: var(--gutter); }
@media (min-width: 768px) { .grid-12 { grid-template-columns: repeat(12, 1fr); } }

.col-span-4 { grid-column: span 1; }
.col-span-8 { grid-column: span 1; }
@media (min-width: 768px) { .col-span-4 { grid-column: span 4; } .col-span-8 { grid-column: span 8; } }

/* --- Header / Navbar --- */
.navbar {
    position: fixed; top: 0; left: 0; width: 100%; z-index: 50;
    display: flex; justify-content: space-between; align-items: center;
    padding: 0 24px; height: 80px;
    background: rgba(255,255,255,0.9); backdrop-filter: blur(16px);
    border-bottom: 1px solid #e2e8f0;
    box-shadow: var(--shadow-card);
    transition: all 0.3s ease;
}
@media (min-width: 768px) { .navbar { padding: 0 48px; } }

.navbar__logo {
    font-family: var(--font-headline); font-size: 1.5rem; font-weight: 900;
    color: var(--on-surface); text-transform: uppercase; letter-spacing: 0.1em;
}

.navbar__nav { display: none; align-items: center; gap: 32px; }
@media (min-width: 768px) { .navbar__nav { display: flex; } }

.navbar__link {
    font-family: var(--font-headline); font-weight: 600; font-size: 15px;
    color: #475569; transition: color 0.2s;
}
.navbar__link:hover, .navbar__link--active {
    color: var(--primary);
}
.navbar__link--active { border-bottom: 2px solid var(--primary); padding-bottom: 4px; }

.navbar__cta {
    background: var(--primary); color: var(--on-primary);
    padding: 10px 24px; border-radius: var(--rounded-lg);
    font-family: var(--font-headline); font-weight: 700; font-size: 14px;
    text-transform: uppercase; letter-spacing: 0.05em;
    border: none; cursor: pointer; transition: background 0.2s;
}
.navbar__cta:hover { background: var(--primary-container); }

/* Mobile menu button */
.navbar__toggle {
    display: flex; flex-direction: column; gap: 5px; background: none; border: none;
    cursor: pointer; padding: 8px;
}
@media (min-width: 768px) { .navbar__toggle { display: none; } }
.navbar__toggle span {
    display: block; width: 24px; height: 2px; background: var(--on-surface);
    transition: transform 0.3s;
}

/* Mobile nav */
.mobile-nav {
    display: none; position: fixed; top: 80px; left: 0; width: 100%; z-index: 49;
    background: white; border-bottom: 1px solid #e2e8f0;
    flex-direction: column; padding: 24px; gap: 16px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.1);
}
.mobile-nav.active { display: flex; }
.mobile-nav a {
    font-family: var(--font-headline); font-weight: 600; font-size: 16px;
    color: #475569; padding: 12px 0; border-bottom: 1px solid #f1f5f9;
}

/* --- Buttons --- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 14px 32px; border: none; cursor: pointer;
    font-family: var(--font-headline); font-weight: 700; font-size: 14px;
    text-transform: uppercase; letter-spacing: 0.05em;
    transition: all 0.3s ease; border-radius: var(--rounded);
}
.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white; box-shadow: 0 4px 16px rgba(0,63,135,0.2);
}
.btn-primary:hover { box-shadow: 0 8px 32px rgba(0,63,135,0.3); transform: translateY(-2px); }

.btn-outline {
    background: transparent; border: 2px solid var(--primary);
    color: var(--primary);
}
.btn-outline:hover { background: var(--primary); color: white; }

.btn-dark {
    background: var(--inverse-surface); color: var(--inverse-on-surface);
}
.btn-dark:hover { background: var(--tertiary); }

.btn-outline-dark { background: transparent; border: 2px solid var(--on-surface); color: var(--on-surface); }
.btn-outline-dark:hover { background: var(--on-surface); color: white; }

/* --- Hero Section --- */
.hero {
    position: relative; display: flex; flex-direction: column;
    min-height: 600px; overflow: hidden;
}
@media (min-width: 768px) { .hero { flex-direction: row; min-height: 90vh; } }

.hero__content {
    width: 100%; display: flex; align-items: center; justify-content: center;
    padding: 120px 24px 48px;
    background-image: linear-gradient(rgba(0,63,135,0.05) 1px, transparent 1px),
                      linear-gradient(90deg, rgba(0,63,135,0.05) 1px, transparent 1px);
    background-size: 40px 40px;
}
@media (min-width: 768px) { .hero__content { width: 50%; padding: 80px 64px; } }

.hero__eyebrow {
    display: inline-block; padding: 6px 16px;
    background: var(--secondary-container); color: white;
    font-family: var(--font-headline); font-size: 12px; font-weight: 700;
    text-transform: uppercase; letter-spacing: 0.15em;
    margin-bottom: 24px; border-radius: var(--rounded-sm);
}

.hero__title {
    font-family: var(--font-headline); font-size: clamp(36px, 5vw, 48px);
    font-weight: 700; line-height: 1.1; letter-spacing: -0.02em;
    color: var(--primary); margin-bottom: 24px;
}

.hero__desc {
    font-family: var(--font-body); font-size: 18px; line-height: 1.6;
    color: var(--on-surface-variant); margin-bottom: 40px; max-width: 480px;
}

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

.hero__image {
    width: 100%; position: relative; min-height: 400px;
}
@media (min-width: 768px) { .hero__image { width: 50%; } }

.hero__image img {
    position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
    clip-path: polygon(0 0, 100% 0, 100% 100%, 15% 100%);
}
@media (max-width: 767px) { .hero__image img { clip-path: none; } }

/* --- Service Cards --- */
.service-card {
    background: var(--surface-container-lowest);
    border: 1px solid var(--outline-variant);
    display: flex; flex-direction: column;
    transition: all 0.3s ease; overflow: hidden;
    border-radius: var(--rounded);
}
.service-card:hover {
    box-shadow: var(--shadow-card);
    border-color: var(--primary);
}

.service-card__image {
    aspect-ratio: 16/9; overflow: hidden;
}
.service-card__image img {
    width: 100%; height: 100%; object-fit: cover;
    transition: transform 0.5s ease;
}
.service-card:hover .service-card__image img { transform: scale(1.05); }

.service-card__body { padding: 32px; flex-grow: 1; display: flex; flex-direction: column; }

.service-card__header { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.service-card__header .material-symbols-outlined { color: var(--primary); font-size: 24px; }
.service-card__title { font-family: var(--font-headline); font-size: 20px; font-weight: 600; color: var(--primary); }

.service-card__desc { color: var(--on-surface-variant); margin-bottom: 24px; }

.service-card__features { display: flex; flex-direction: column; gap: 12px; margin-bottom: 32px; }
.service-card__feature {
    display: flex; align-items: center; gap: 8px;
    font-family: var(--font-headline); font-size: 13px; font-weight: 500; color: var(--tertiary);
}
.service-card__feature .material-symbols-outlined { font-size: 16px; color: var(--primary); }

.service-card__btn {
    margin-top: auto; width: 100%; padding: 14px;
    border: 2px solid var(--primary); background: transparent; color: var(--primary);
    font-family: var(--font-headline); font-weight: 700; font-size: 13px;
    text-transform: uppercase; letter-spacing: 0.1em; cursor: pointer;
    text-align: center; display: block;
    transition: all 0.3s ease;
}
.service-card__btn:hover { background: var(--primary); color: white; }

/* --- Bento/Masonry Cards (Homepage) --- */
.bento-card {
    position: relative; overflow: hidden; border-radius: var(--rounded-xl);
    border: 1px solid var(--outline-variant);
    transition: all 0.3s ease;
}
.bento-card:hover { border-color: var(--primary); }
.bento-card--large { height: 450px; }
.bento-card--medium { height: 300px; }

.bento-card__image {
    position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
    transition: transform 0.5s ease;
}
.bento-card:hover .bento-card__image { transform: scale(1.05); }

.bento-card__overlay {
    position: absolute; inset: 0;
    background: linear-gradient(to top, rgba(0,63,135,0.85), transparent);
}
.bento-card__overlay--dark {
    background: linear-gradient(to top, rgba(65,65,65,0.9), transparent);
}

.bento-card__content {
    position: absolute; bottom: 0; left: 0; padding: 32px; color: white; z-index: 2;
}
.bento-card__content h3 { font-family: var(--font-headline); font-size: 24px; font-weight: 600; margin-bottom: 8px; }
.bento-card__content p { opacity: 0.8; max-width: 400px; }

/* Icon cards */
.icon-card {
    background: white; border-radius: var(--rounded-xl); border: 1px solid var(--outline-variant);
    padding: 32px; display: flex; flex-direction: column; height: 300px;
    transition: all 0.3s ease;
}
.icon-card:hover { box-shadow: 0 12px 48px rgba(0,0,0,0.08); }

.icon-card__icon {
    width: 48px; height: 48px; background: rgba(0,63,135,0.1);
    border-radius: var(--rounded-lg); display: flex; align-items: center; justify-content: center;
    color: var(--primary); margin-bottom: 24px;
}

.icon-card__title { font-family: var(--font-headline); font-size: 20px; font-weight: 600; color: var(--primary); margin-bottom: 8px; }
.icon-card__desc { color: var(--on-surface-variant); }

.icon-card__link {
    margin-top: auto; padding-top: 16px; border-top: 1px solid rgba(194,198,212,0.3);
    font-family: var(--font-headline); font-weight: 700; font-size: 14px;
    color: var(--primary); display: flex; align-items: center; gap: 8px;
    text-transform: uppercase; letter-spacing: 0.05em;
    transition: gap 0.3s ease;
}
.icon-card:hover .icon-card__link { gap: 16px; }

/* CTA card */
.cta-card {
    background: var(--primary); border-radius: var(--rounded-xl);
    display: flex; align-items: center; justify-content: center; text-align: center;
    padding: 32px; position: relative; overflow: hidden; height: 300px;
}
.cta-card h3 { font-family: var(--font-headline); font-size: 24px; font-weight: 600; color: white; margin-bottom: 16px; }
.cta-card p { color: var(--on-primary-container); margin-bottom: 24px; }
.cta-card .btn { background: white; color: var(--primary); }

/* --- Stats Section --- */
.stats {
    background: var(--tertiary); padding: 80px 0; color: white;
}
.stats__grid {
    display: grid; grid-template-columns: repeat(2, 1fr); gap: 48px; text-align: center;
}
@media (min-width: 768px) { .stats__grid { grid-template-columns: repeat(4, 1fr); } }

.stats__number {
    font-family: var(--font-headline); font-size: clamp(36px, 5vw, 48px);
    font-weight: 700; margin-bottom: 8px;
}
.stats__label {
    font-family: var(--font-headline); font-size: 12px; font-weight: 700;
    text-transform: uppercase; letter-spacing: 0.15em; opacity: 0.7;
}

/* --- Trust/Quality Section --- */
.trust { background: var(--inverse-surface); padding: 64px 0; color: white; overflow: hidden; }
.trust__stats { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 48px; }
@media (min-width: 768px) { .trust__stats { gap: 96px; } }
.trust__divider { width: 1px; height: 64px; background: #475569; display: none; }
@media (min-width: 768px) { .trust__divider { display: block; } }
.trust__stat { text-align: center; }
.trust__badges { display: flex; flex-wrap: wrap; justify-content: center; gap: 16px; margin-top: 48px; }
.trust__badge {
    background: #1e293b; padding: 8px 24px; border-radius: 9999px;
    border: 1px solid #334155; display: flex; align-items: center; gap: 8px;
    font-family: var(--font-headline); font-size: 12px; font-weight: 500;
}

/* --- CTA Section --- */
.cta-section { padding: var(--section-padding) 0; background: white; text-align: center; }
.cta-section__title { color: var(--primary); margin-bottom: 24px; }
.cta-section__desc { color: var(--on-surface-variant); max-width: 640px; margin: 0 auto 40px; }
.cta-section__actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 16px; }

/* --- Footer --- */
.footer {
    background: #0f172a; color: #94a3b8; padding: 64px 0 0;
    font-family: var(--font-headline); font-size: 14px;
}
.footer__grid {
    display: grid; grid-template-columns: 1fr; gap: 48px;
}
@media (min-width: 768px) { .footer__grid { grid-template-columns: 1.5fr 1fr 1fr 1fr; } }

.footer__brand { font-size: 20px; font-weight: 800; color: white; margin-bottom: 16px; }
.footer__desc { line-height: 1.6; margin-bottom: 24px; }
.footer__social { display: flex; gap: 12px; }
.footer__social-icon {
    width: 40px; height: 40px; background: #1e293b; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    color: #94a3b8; transition: color 0.2s; cursor: pointer;
}
.footer__social-icon:hover { color: var(--secondary-container); }

.footer__heading { color: white; font-weight: 600; font-size: 16px; margin-bottom: 24px; }
.footer__links { display: flex; flex-direction: column; gap: 16px; }
.footer__link { color: #94a3b8; transition: all 0.2s; }
.footer__link:hover { color: #60a5fa; transform: translateX(4px); }

.footer__contact-phone { color: white; font-weight: 700; margin-bottom: 8px; }
.footer__contact-email { color: #94a3b8; transition: color 0.2s; }
.footer__contact-email:hover { color: #60a5fa; }

.footer__bottom {
    margin-top: 48px; padding: 24px 0; border-top: 1px solid #1e293b;
    text-align: center; font-size: 12px; opacity: 0.5;
}

/* --- Breadcrumb --- */
.breadcrumb {
    display: flex; align-items: center; gap: 8px; padding: 16px 0;
    font-family: var(--font-headline); font-size: 14px; color: var(--outline);
}
.breadcrumb a { color: var(--primary); transition: opacity 0.2s; }
.breadcrumb a:hover { opacity: 0.7; }
.breadcrumb__sep { color: var(--outline-variant); }

/* --- Page Hero (inner pages) --- */
.page-hero {
    position: relative; height: 400px; display: flex; align-items: center;
    overflow: hidden; background: var(--inverse-surface);
}
.page-hero__bg {
    position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0.4;
}
.page-hero__content {
    position: relative; z-index: 2; max-width: 640px;
    border-left: 4px solid var(--primary); padding-left: 32px;
}
.page-hero__eyebrow {
    font-family: var(--font-headline); font-size: 14px; font-weight: 700;
    color: var(--secondary-container); text-transform: uppercase;
    letter-spacing: 0.2em; margin-bottom: 16px;
}
.page-hero__title { font-family: var(--font-headline); font-size: 40px; font-weight: 700; color: white; margin-bottom: 16px; }
.page-hero__desc { font-size: 18px; color: #cbd5e1; }

/* --- Contact Form --- */
.form-group { margin-bottom: 24px; }
.form-label {
    display: block; margin-bottom: 8px;
    font-family: var(--font-headline); font-size: 14px; font-weight: 700;
    letter-spacing: 0.05em; color: var(--on-surface);
}
.form-input, .form-textarea, .form-select {
    width: 100%; padding: 14px 16px;
    border: 1px solid var(--tertiary); border-radius: var(--rounded);
    font-family: var(--font-body); font-size: 16px; color: var(--on-surface);
    background: white; transition: border-color 0.2s;
}
.form-input:focus, .form-textarea:focus, .form-select:focus {
    outline: none; border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(0,63,135,0.1);
}
.form-textarea { min-height: 120px; resize: vertical; }
.form-error { color: var(--error); font-size: 13px; margin-top: 4px; }

/* --- Utilities --- */
.text-primary { color: var(--primary); }
.text-white { color: white; }
.text-muted { color: var(--on-surface-variant); }
.bg-surface { background: var(--surface); }
.bg-white { background: white; }
.mt-20 { margin-top: 80px; }
.pt-navbar { padding-top: 80px; }
.text-center { text-align: center; }
.mx-auto { margin-left: auto; margin-right: auto; }
.max-w-3xl { max-width: 768px; }
.flex { display: flex; }
.flex-wrap { flex-wrap: wrap; }
.gap-4 { gap: 16px; }
.gap-6 { gap: 24px; }
.justify-center { justify-content: center; }
.items-center { align-items: center; }

/* --- Animations --- */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(24px); }
    to { opacity: 1; transform: translateY(0); }
}
.animate-in { animation: fadeInUp 0.6s ease-out forwards; }
.animate-delay-1 { animation-delay: 0.1s; }
.animate-delay-2 { animation-delay: 0.2s; }
.animate-delay-3 { animation-delay: 0.3s; }

/* --- Responsive --- */
@media (max-width: 767px) {
    .section { padding: 48px 0; }
    .headline-xl { font-size: 32px; }
    .headline-lg { font-size: 26px; }
    .page-hero { height: 300px; }
    .page-hero__title { font-size: 28px; }
}

/* --- Diagonal BG Pattern --- */
.diagonal-bg {
    background-image: linear-gradient(45deg, rgba(0,63,135,0.05) 25%, transparent 25%, transparent 50%, rgba(0,63,135,0.05) 50%, rgba(0,63,135,0.05) 75%, transparent 75%, transparent);
    background-size: 40px 40px;
}
.industrial-grid {
    background-image: linear-gradient(rgba(0,63,135,0.05) 1px, transparent 1px),
                      linear-gradient(90deg, rgba(0,63,135,0.05) 1px, transparent 1px);
    background-size: 40px 40px;
}
