/* DotCity Technologies - Shared Theme */
:root {
    --primary: #7c3aed;
    --primary-dark: #6d28d9;
    --primary-darker: #5b21b6;
    --primary-light: #ede9fe;
    --primary-lighter: #f5f3ff;
    --secondary: #111827;
    --accent: #a855f7;
    --text-dark: #1f2937;
    --text-mid: #4b5563;
    --text-light: #9ca3af;
    --white: #ffffff;
    --bg-light: #f9fafb;
    --border: #e5e7eb;
    --radius: 0.75rem;
    --shadow: 0 4px 6px -1px rgba(0,0,0,0.1), 0 2px 4px -1px rgba(0,0,0,0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.1), 0 4px 6px -2px rgba(0,0,0,0.05);
    --bottom-nav-height: 68px;
}

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

body {
    font-family: 'Inter', sans-serif;
    color: var(--text-dark);
    background: var(--bg-light);
    padding-bottom: var(--bottom-nav-height);
    min-height: 100vh;
}

/* ===================== TOP HEADER ===================== */
.top-header {
    background: var(--white);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: var(--shadow);
}
.top-header .inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.25rem;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.logo {
    font-size: 1.4rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-decoration: none;
    letter-spacing: -0.5px;
}
.logo span { font-weight: 400; }

.header-actions { display: flex; align-items: center; gap: 0.75rem; }
.btn { display: inline-flex; align-items: center; gap: 0.4rem; padding: 0.5rem 1.1rem; border-radius: var(--radius); font-weight: 600; font-size: 0.875rem; cursor: pointer; transition: all 0.2s; text-decoration: none; border: none; }
.btn-primary { background: linear-gradient(135deg, var(--primary), var(--primary-dark)); color: var(--white); }
.btn-primary:hover { background: linear-gradient(135deg, var(--primary-dark), var(--primary-darker)); transform: translateY(-1px); box-shadow: 0 4px 12px rgba(124,58,237,0.35); }
.btn-outline { background: transparent; color: var(--primary); border: 1.5px solid var(--primary); }
.btn-outline:hover { background: var(--primary-lighter); }
.btn-sm { padding: 0.35rem 0.85rem; font-size: 0.8rem; }

/* ===================== HERO ===================== */
.hero {
    background: linear-gradient(135deg, var(--secondary) 0%, #1f1048 60%, var(--primary-dark) 100%);
    color: var(--white);
    padding: 4rem 1.25rem 3rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}
.hero::before {
    content: '';
    position: absolute; inset: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}
.hero .inner { position: relative; max-width: 800px; margin: 0 auto; }
.hero-badge { display: inline-block; background: rgba(168,85,247,0.2); border: 1px solid rgba(168,85,247,0.4); color: #c4b5fd; padding: 0.3rem 1rem; border-radius: 100px; font-size: 0.8rem; font-weight: 600; margin-bottom: 1.25rem; letter-spacing: 0.5px; text-transform: uppercase; }
.hero h1 { font-size: clamp(2rem, 5vw, 3.25rem); font-weight: 800; line-height: 1.15; margin-bottom: 1rem; }
.hero h1 .highlight { color: #c4b5fd; }
.hero p { font-size: 1.1rem; color: #d1d5db; max-width: 600px; margin: 0 auto 2rem; line-height: 1.7; }
.hero-cta { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }

/* ===================== SECTIONS ===================== */
.section { padding: 3.5rem 1.25rem; }
.section-alt { background: var(--white); }
.container { max-width: 1200px; margin: 0 auto; }
.section-header { text-align: center; margin-bottom: 2.5rem; }
.section-label { font-size: 0.8rem; font-weight: 700; color: var(--primary); text-transform: uppercase; letter-spacing: 1px; margin-bottom: 0.5rem; }
.section-header h2 { font-size: clamp(1.6rem, 3vw, 2.25rem); font-weight: 800; color: var(--secondary); margin-bottom: 0.75rem; }
.section-header p { color: var(--text-mid); max-width: 560px; margin: 0 auto; line-height: 1.7; }

/* ===================== CARDS ===================== */
.cards-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 1.5rem; }
.card { background: var(--white); border-radius: var(--radius); border: 1px solid var(--border); padding: 1.75rem; transition: all 0.25s; }
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: var(--primary-light); }
.card-icon { width: 52px; height: 52px; border-radius: var(--radius); background: var(--primary-lighter); display: flex; align-items: center; justify-content: center; margin-bottom: 1.1rem; font-size: 1.3rem; color: var(--primary); }
.card h3 { font-size: 1.05rem; font-weight: 700; color: var(--secondary); margin-bottom: 0.5rem; }
.card p { font-size: 0.9rem; color: var(--text-mid); line-height: 1.6; }
.card-link { display: inline-flex; align-items: center; gap: 0.35rem; margin-top: 1rem; font-size: 0.85rem; font-weight: 600; color: var(--primary); text-decoration: none; }
.card-link:hover { gap: 0.6rem; }

/* ===================== SUBSIDIARIES ===================== */
.subs-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1.25rem; }
.sub-card { background: var(--white); border-radius: var(--radius); border: 2px solid var(--border); padding: 1.5rem; text-decoration: none; color: inherit; transition: all 0.25s; display: flex; flex-direction: column; align-items: flex-start; gap: 0.75rem; }
.sub-card:hover { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(124,58,237,0.1); transform: translateY(-2px); }
.sub-card .sub-icon { font-size: 1.6rem; }
.sub-card .sub-name { font-weight: 700; font-size: 1rem; color: var(--secondary); }
.sub-card .sub-desc { font-size: 0.82rem; color: var(--text-mid); line-height: 1.5; }
.sub-card .sub-url { font-size: 0.75rem; color: var(--primary); font-weight: 600; }
.sub-card.active { border-color: var(--primary); background: var(--primary-lighter); }

/* ===================== STATS ===================== */
.stats-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 1.5rem; text-align: center; }
.stat-item .stat-num { font-size: 2.25rem; font-weight: 800; color: var(--primary); line-height: 1; }
.stat-item .stat-label { font-size: 0.85rem; color: var(--text-mid); margin-top: 0.3rem; }

/* ===================== TESTIMONIALS ===================== */
.testimonials-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1.5rem; }
.testimonial-card { background: var(--white); border-radius: var(--radius); border: 1px solid var(--border); padding: 1.5rem; }
.testimonial-card .stars { color: #f59e0b; font-size: 0.9rem; margin-bottom: 0.75rem; }
.testimonial-card .quote { font-size: 0.92rem; color: var(--text-mid); line-height: 1.7; font-style: italic; margin-bottom: 1rem; }
.testimonial-card .author { display: flex; align-items: center; gap: 0.6rem; }
.testimonial-card .avatar { width: 36px; height: 36px; border-radius: 50%; background: var(--primary); display: flex; align-items: center; justify-content: center; font-weight: 700; color: white; font-size: 0.85rem; }
.testimonial-card .author-info .name { font-weight: 700; font-size: 0.9rem; }
.testimonial-card .author-info .role { font-size: 0.78rem; color: var(--text-light); }

/* ===================== CONTACT FORM ===================== */
.contact-wrap { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: start; }
@media(max-width:768px){ .contact-wrap { grid-template-columns: 1fr; } }
.form-group { margin-bottom: 1.1rem; }
.form-label { display: block; font-size: 0.85rem; font-weight: 600; color: var(--text-dark); margin-bottom: 0.4rem; }
.form-control { width: 100%; padding: 0.65rem 0.9rem; border: 1.5px solid var(--border); border-radius: var(--radius); font-size: 0.9rem; font-family: inherit; transition: border 0.2s; background: var(--white); color: var(--text-dark); }
.form-control:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(124,58,237,0.12); }
textarea.form-control { resize: vertical; min-height: 120px; }
select.form-control { cursor: pointer; }

/* ===================== FOOTER ===================== */
.main-footer { background: var(--secondary); color: #d1d5db; padding: 3rem 1.25rem 1.5rem; }
.footer-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 2rem; max-width: 1200px; margin: 0 auto; }
@media(max-width:900px){ .footer-grid { grid-template-columns: 1fr 1fr; } }
@media(max-width:560px){ .footer-grid { grid-template-columns: 1fr; } }
.footer-brand .logo { font-size: 1.3rem; margin-bottom: 0.75rem; display: block; }
.footer-brand p { font-size: 0.85rem; line-height: 1.7; color: #9ca3af; }
.footer-col h4 { font-weight: 700; color: var(--white); margin-bottom: 1rem; font-size: 0.9rem; text-transform: uppercase; letter-spacing: 0.5px; }
.footer-col ul { list-style: none; }
.footer-col ul li { margin-bottom: 0.6rem; }
.footer-col ul li a { color: #9ca3af; text-decoration: none; font-size: 0.875rem; transition: color 0.2s; }
.footer-col ul li a:hover { color: #c4b5fd; }
.footer-bottom { max-width: 1200px; margin: 2rem auto 0; padding-top: 1.5rem; border-top: 1px solid #374151; display: flex; justify-content: space-between; align-items: center; font-size: 0.8rem; color: #6b7280; flex-wrap: wrap; gap: 0.5rem; }

/* ===================== BOTTOM NAV ===================== */
.bottom-nav {
    position: fixed; bottom: 0; left: 0; right: 0;
    background: var(--white);
    border-top: 1px solid var(--border);
    height: var(--bottom-nav-height);
    display: flex; align-items: center;
    z-index: 200;
    box-shadow: 0 -4px 12px rgba(0,0,0,0.08);
}
.bottom-nav .nav-items { display: flex; width: 100%; justify-content: space-around; align-items: center; padding: 0 0.5rem; }
.bottom-nav .nav-item { display: flex; flex-direction: column; align-items: center; gap: 0.25rem; padding: 0.4rem 0.75rem; border-radius: var(--radius); text-decoration: none; color: var(--text-light); font-size: 0.7rem; font-weight: 500; transition: all 0.2s; flex: 1; max-width: 80px; }
.bottom-nav .nav-item i { font-size: 1.2rem; }
.bottom-nav .nav-item:hover, .bottom-nav .nav-item.active { color: var(--primary); }
.bottom-nav .nav-item.active i { transform: scale(1.1); }
.bottom-nav .nav-item .nav-label { font-size: 0.68rem; }

/* ===================== ALERT / BANNER ===================== */
.alert { padding: 0.85rem 1.25rem; border-radius: var(--radius); margin-bottom: 1rem; font-size: 0.9rem; display: flex; align-items: center; gap: 0.6rem; }
.alert-info { background: #eff6ff; color: #1d4ed8; border: 1px solid #bfdbfe; }
.alert-success { background: #f0fdf4; color: #166534; border: 1px solid #bbf7d0; }
.alert-warning { background: #fffbeb; color: #92400e; border: 1px solid #fde68a; }

/* ===================== PAGE HEADER ===================== */
.page-header { background: linear-gradient(135deg, var(--secondary), #1f1048); color: var(--white); padding: 2.5rem 1.25rem 2rem; }
.page-header .inner { max-width: 1200px; margin: 0 auto; }
.page-header h1 { font-size: clamp(1.6rem, 3vw, 2.25rem); font-weight: 800; margin-bottom: 0.5rem; }
.page-header p { color: #d1d5db; font-size: 0.95rem; }
.breadcrumb { display: flex; gap: 0.5rem; align-items: center; font-size: 0.8rem; color: #9ca3af; margin-bottom: 0.75rem; }
.breadcrumb a { color: #c4b5fd; text-decoration: none; }
.breadcrumb a:hover { text-decoration: underline; }

/* ===================== UTILS ===================== */
.text-center { text-align: center; }
.mt-1 { margin-top: 0.5rem; } .mt-2 { margin-top: 1rem; } .mt-3 { margin-top: 1.5rem; } .mt-4 { margin-top: 2rem; }
.mb-1 { margin-bottom: 0.5rem; } .mb-2 { margin-bottom: 1rem; } .mb-3 { margin-bottom: 1.5rem; }
.d-flex { display: flex; } .align-center { align-items: center; } .justify-between { justify-content: space-between; }
.gap-1 { gap: 0.5rem; } .gap-2 { gap: 1rem; }
.w-full { width: 100%; }
.badge { display: inline-block; padding: 0.2rem 0.65rem; border-radius: 100px; font-size: 0.75rem; font-weight: 600; }
.badge-purple { background: var(--primary-lighter); color: var(--primary); }
.badge-green { background: #f0fdf4; color: #166534; }
.badge-red { background: #fef2f2; color: #991b1b; }

/* ===================== DESKTOP NAV ===================== */
.desktop-nav { display: flex; align-items: center; gap: 1.25rem; }
.desktop-nav a { font-size: 0.875rem; font-weight: 500; color: var(--text-mid); text-decoration: none; transition: color 0.2s; }
.desktop-nav a:hover, .desktop-nav a.active { color: var(--primary); }

/* ===================== RESPONSIVE LAYOUT HELPERS ===================== */
/* Two-column grids used in services.php — collapse to 1 col on mobile */
.two-col-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: center;
}
/* Subsidiary detail card: 2fr/1fr */
.sub-detail-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 2.5rem;
    align-items: start;
}

/* ===================== RESPONSIVE ===================== */
@media (max-width: 768px) {
    /* Two-column layouts → single column */
    .two-col-grid,
    .sub-detail-grid {
        grid-template-columns: 1fr;
        gap: 1.75rem;
    }
    /* Restore natural order for reversed columns */
    .two-col-grid > *,
    .sub-detail-grid > * {
        order: unset !important;
    }
    /* Services section dark preview card sits below text */
    .two-col-grid .preview-card { order: 1 !important; }
    .two-col-grid .service-text { order: 0 !important; }
}

@media (max-width: 640px) {
    /* Header — hide portal buttons, show only hamburger */
    .header-portal-btns { display: none !important; }
    .desktop-nav { display: none; }

    /* Hero */
    .hero { padding: 2.5rem 1rem 2rem; }
    .hero h1 { font-size: 1.8rem; }
    .hero p { font-size: 0.95rem; }
    .hero-cta { flex-direction: column; align-items: center; }
    .hero-cta .btn { width: 100%; max-width: 280px; justify-content: center; }

    /* Sections */
    .section { padding: 2.25rem 1rem; }
    .section-header { margin-bottom: 1.75rem; }

    /* Cards */
    .cards-grid { grid-template-columns: 1fr; gap: 1rem; }
    .subs-grid { grid-template-columns: 1fr; gap: 0.9rem; }
    .testimonials-grid { grid-template-columns: 1fr; }

    /* Sub-card strip in footer */
    .subs-strip { flex-direction: column; }

    /* Buttons */
    .btn { font-size: 0.85rem; }

    /* CTA section button group */
    .cta-btn-group { flex-direction: column; align-items: center; }
    .cta-btn-group .btn { width: 100%; max-width: 280px; justify-content: center; }

    /* Subsidiaries detail view */
    .sub-detail-grid { grid-template-columns: 1fr; gap: 1.25rem; }

    /* Page header */
    .page-header { padding: 1.75rem 1rem 1.5rem; }
    .page-header h1 { font-size: 1.5rem; }
}

@media (max-width: 420px) {
    .logo { font-size: 1.2rem; }
    .hero h1 { font-size: 1.5rem; }
    .stat-item .stat-num { font-size: 1.75rem; }
}

/* Divider */
.divider { border: none; border-top: 1px solid var(--border); margin: 2rem 0; }
