/* ============================================
   TGMed — Medical Device Consulting
   Premium Medical Professional Design System
   ============================================ */

/* --- CSS Variables --- */
:root {
    --navy: #0A2540;
    --navy-light: #132D4A;
    --blue: #2F80ED;
    --blue-hover: #1A6FDB;
    --teal: #2A9D8F;
    --teal-light: rgba(42, 157, 143, 0.1);
    --bg: #F8FAFC;
    --bg-alt: #F1F5F9;
    --white: #FFFFFF;
    --text: #111827;
    --text-secondary: #5B6B7A;
    --text-light: #94A3B8;
    --border: #E2E8F0;
    --shadow-sm: 0 1px 3px rgba(10, 37, 64, 0.06);
    --shadow-md: 0 4px 16px rgba(10, 37, 64, 0.08);
    --shadow-lg: 0 8px 32px rgba(10, 37, 64, 0.12);
    --radius: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--text);
    background: var(--white);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4 {
    font-family: 'Plus Jakarta Sans', 'Inter', sans-serif;
    font-weight: 700;
    line-height: 1.15;
    color: var(--navy);
}

h1 { font-size: clamp(2.25rem, 5vw, 3.5rem); letter-spacing: -0.03em; }
h2 { font-size: clamp(1.75rem, 3.5vw, 2.75rem); letter-spacing: -0.02em; }
h3 { font-size: clamp(1.25rem, 2vw, 1.5rem); letter-spacing: -0.01em; }
h4 { font-size: 1.125rem; }

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

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

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* --- Header --- */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid transparent;
    transition: border-color var(--transition), box-shadow var(--transition);
}

.header.scrolled {
    border-bottom-color: var(--border);
    box-shadow: var(--shadow-sm);
}

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

.logo {
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 1.5rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    gap: 0;
}

.logo-tg { color: var(--navy); }
.logo-med { color: var(--teal); }
.logo-sro { color: var(--text-secondary); font-size: 0.7em; font-weight: 400; }

.nav-links {
    display: flex;
    list-style: none;
    gap: 32px;
}

.nav-links a {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-secondary);
    letter-spacing: 0.01em;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--teal);
    transition: width var(--transition);
}

.nav-links a:hover {
    color: var(--navy);
}

.nav-links a:hover::after {
    width: 100%;
}

.nav-cta {
    font-size: 0.875rem;
}

.mobile-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
}

.mobile-toggle span {
    width: 22px;
    height: 2px;
    background: var(--navy);
    border-radius: 2px;
    transition: var(--transition);
}

/* --- Buttons --- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 24px;
    border-radius: var(--radius);
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    font-size: 0.9375rem;
    border: none;
    cursor: pointer;
    transition: all var(--transition);
    text-decoration: none;
}

.btn-primary {
    background: var(--teal);
    color: var(--white);
    box-shadow: 0 2px 8px rgba(42, 157, 143, 0.25);
}

.btn-primary:hover {
    background: #238B7E;
    box-shadow: 0 4px 16px rgba(42, 157, 143, 0.35);
    transform: translateY(-1px);
}

.btn-outline {
    background: transparent;
    color: var(--navy);
    border: 1.5px solid var(--border);
}

.btn-outline:hover {
    border-color: var(--navy);
    background: var(--bg);
}

.btn-white {
    background: var(--white);
    color: var(--navy);
}

.btn-white:hover {
    background: var(--bg);
    transform: translateY(-1px);
}

.btn-lg {
    padding: 14px 32px;
    font-size: 1rem;
}

.btn-full {
    width: 100%;
}

/* --- Hero --- */
.hero {
    position: relative;
    padding: 160px 0 100px;
    background: var(--white);
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    top: 0;
    right: 0;
    width: 55%;
    height: 100%;
    background: linear-gradient(135deg, var(--bg) 0%, rgba(42, 157, 143, 0.04) 100%);
    border-radius: 0 0 0 40%;
    z-index: 0;
}

.hero-bg::before {
    content: '';
    position: absolute;
    top: 15%;
    right: 8%;
    width: 300px;
    height: 300px;
    border: 1px solid rgba(42, 157, 143, 0.12);
    border-radius: 50%;
}

.hero-bg::after {
    content: '';
    position: absolute;
    top: 25%;
    right: 15%;
    width: 200px;
    height: 200px;
    border: 1px solid rgba(42, 157, 143, 0.08);
    border-radius: 50%;
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 680px;
}

.hero-badge {
    display: inline-block;
    padding: 6px 16px;
    background: var(--teal-light);
    color: var(--teal);
    font-size: 0.8125rem;
    font-weight: 600;
    border-radius: 100px;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    margin-bottom: 24px;
}

.text-gradient {
    background: linear-gradient(135deg, var(--teal) 0%, var(--blue) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-sub {
    font-size: 1.125rem;
    color: var(--text-secondary);
    line-height: 1.7;
    margin-top: 20px;
    max-width: 560px;
}

.hero-actions {
    display: flex;
    gap: 16px;
    margin-top: 36px;
    flex-wrap: wrap;
}

.hero-trust {
    display: flex;
    gap: 24px;
    margin-top: 48px;
    flex-wrap: wrap;
}

.trust-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--text-secondary);
}

/* --- Section Styles --- */
.section-label {
    display: inline-block;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--teal);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 12px;
}

.section-header {
    text-align: center;
    max-width: 640px;
    margin: 0 auto 64px;
}

.section-header p {
    color: var(--text-secondary);
    margin-top: 16px;
    font-size: 1.0625rem;
}

/* --- Services --- */
.services {
    padding: 100px 0;
    background: var(--bg);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.service-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    padding: 36px 32px;
    border: 1px solid var(--border);
    transition: all var(--transition);
    position: relative;
}

.service-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: transparent;
}

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

.service-number {
    position: absolute;
    top: 32px;
    right: 32px;
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 0.8125rem;
    font-weight: 700;
    color: var(--text-light);
}

.service-card h3 {
    font-size: 1.1875rem;
    margin-bottom: 12px;
    line-height: 1.3;
}

.service-card p {
    font-size: 0.9375rem;
    color: var(--text-secondary);
    line-height: 1.65;
}

.service-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 20px;
    list-style: none;
}

.service-tags li {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--teal);
    background: var(--teal-light);
    padding: 4px 12px;
    border-radius: 100px;
}

/* --- Results / Stats --- */
.results {
    padding: 80px 0;
    background: var(--navy);
}

.results-grid {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 48px;
    flex-wrap: wrap;
}

.stat {
    text-align: center;
}

.stat-number {
    display: block;
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: clamp(2rem, 3vw, 2.75rem);
    font-weight: 800;
    color: var(--teal);
    line-height: 1;
}

.stat-unit {
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--teal);
}

.stat-label {
    display: block;
    margin-top: 8px;
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.65);
    font-weight: 400;
}

.stat-divider {
    width: 1px;
    height: 48px;
    background: rgba(255, 255, 255, 0.12);
}

/* --- Why Us --- */
.why-us {
    padding: 100px 0;
    background: var(--white);
}

.why-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 64px;
    align-items: center;
}

.why-content p {
    color: var(--text-secondary);
    margin-top: 16px;
    font-size: 1.0625rem;
}

.why-list {
    list-style: none;
    margin-top: 32px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.why-list li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    font-size: 0.9375rem;
    color: var(--text);
    font-weight: 450;
}

.why-list li svg {
    flex-shrink: 0;
    margin-top: 2px;
}

.why-visual {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.visual-card {
    background: var(--bg);
    border-radius: var(--radius-lg);
    padding: 32px;
    border: 1px solid var(--border);
    transition: all var(--transition);
}

.visual-card:hover {
    box-shadow: var(--shadow-md);
}

.visual-icon {
    margin-bottom: 16px;
}

.visual-card h4 {
    margin-bottom: 8px;
    color: var(--navy);
}

.visual-card p {
    color: var(--text-secondary);
    font-size: 0.9375rem;
}

/* --- CTA Section --- */
.cta-section {
    padding: 80px 0;
    background: linear-gradient(135deg, var(--navy) 0%, var(--navy-light) 100%);
    position: relative;
    overflow: hidden;
}

.cta-section::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 500px;
    height: 500px;
    border: 1px solid rgba(42, 157, 143, 0.15);
    border-radius: 50%;
}

.cta-content {
    position: relative;
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
}

.cta-content h2 {
    color: var(--white);
    margin-bottom: 16px;
}

.cta-content p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 1.0625rem;
    margin-bottom: 32px;
}

/* --- Contact --- */
.contact {
    padding: 100px 0;
    background: var(--bg);
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 64px;
    align-items: start;
}

.contact-info h2 {
    margin-bottom: 16px;
}

.contact-info > p {
    color: var(--text-secondary);
    font-size: 1.0625rem;
    margin-bottom: 32px;
}

.contact-details {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.9375rem;
    color: var(--text);
}

.contact-item svg { flex-shrink: 0; }

.contact-item a:hover { color: var(--teal); }

.contact-form-wrap {
    background: var(--white);
    border-radius: var(--radius-xl);
    padding: 40px;
    box-shadow: var(--shadow-md);
    border: 1px solid var(--border);
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-group label {
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--navy);
}

.form-group input,
.form-group select,
.form-group textarea {
    font-family: 'Inter', sans-serif;
    font-size: 0.9375rem;
    padding: 12px 16px;
    border: 1.5px solid var(--border);
    border-radius: var(--radius);
    background: var(--white);
    color: var(--text);
    transition: border-color var(--transition), box-shadow var(--transition);
    outline: none;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: var(--teal);
    box-shadow: 0 0 0 3px rgba(42, 157, 143, 0.1);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--text-light);
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
}

.form-group select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%235B6B7A' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    padding-right: 40px;
}

/* --- Footer --- */
.footer {
    background: var(--navy);
    padding: 64px 0 32px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr;
    gap: 48px;
}

.footer-brand .logo {
    margin-bottom: 16px;
}

.footer .logo-tg {
    color: var(--white);
}

.footer .logo-med {
    color: var(--teal);
}

.footer .logo-sro {
    color: rgba(255, 255, 255, 0.5);
}

.footer-brand p {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.875rem;
    line-height: 1.7;
    max-width: 280px;
}

.footer-col h4 {
    color: var(--white);
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 16px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.footer-col ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer-col ul li,
.footer-col ul li a,
.footer-col ul li span {
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.5);
}

.footer-col ul li a:hover {
    color: var(--teal);
}

.footer-bottom {
    margin-top: 48px;
    padding-top: 24px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    text-align: center;
}

.footer-bottom p {
    font-size: 0.8125rem;
    color: rgba(255, 255, 255, 0.35);
}

/* --- Animations --- */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(24px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-in {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

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

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

@media (max-width: 768px) {
    .nav-links,
    .nav-cta {
        display: none;
    }

    .mobile-toggle {
        display: flex;
    }

    .nav-links.active {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: 72px;
        left: 0;
        right: 0;
        background: var(--white);
        padding: 24px;
        border-bottom: 1px solid var(--border);
        box-shadow: var(--shadow-md);
        gap: 16px;
    }

    .hero {
        padding: 120px 0 80px;
    }

    .hero-bg {
        width: 100%;
        opacity: 0.4;
    }

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

    .results-grid {
        gap: 32px;
    }

    .stat-divider {
        display: none;
    }

    .why-grid,
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 32px;
    }

    .contact-form-wrap {
        padding: 24px;
    }
}

@media (max-width: 480px) {
    .hero-actions {
        flex-direction: column;
    }

    .hero-trust {
        flex-direction: column;
        gap: 12px;
    }

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

    .results-grid {
        flex-direction: column;
    }
}
