/* Base and Typography */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600&family=Space+Grotesk:wght@500;600&display=swap');

:root {
    --blue: #0e5aa0;
    --green: #4ade80;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    background: #f8fafc;
    color: #222;
    line-height: 1.6;
}

/* Layout for pages with sticky footer */
.body-layout {
    display: flex;
    flex-direction: column;
    align-items: stretch; /* Ensure children stretch to full width */
    min-height: 100vh;
}

.body-layout main {
    flex-grow: 1;
    display: flex; /* Allow main to also be a flex container */
}

/* Utility Classes */
.btn {
    padding: 14px 32px;
    border-radius: 9999px;
    font-weight: 600;
    font-size: 14px;
    min-width: 170px;
    text-align: center;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.35s ease;
    white-space: nowrap;
    text-decoration: none;
    border: 2px solid var(--blue);
    background: white;
    color: var(--blue);
}

.btn:hover {
    background: var(--green);
    color: var(--blue);
    border-color: var(--green);
}

.section {
    max-width: 1280px;
    margin: 0 auto;
    padding: 100px 40px;
}

/* Navbar */
.navbar {
    background: rgba(255, 255, 255, 0.97);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid #e5e7eb;
    position: sticky;
    top: 0;
    z-index: 50;
    padding: 10px 0;
}

.nav-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 40px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    height: 75px;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 32px;
    font-weight: 500;
    font-size: 15px;
}

.nav-menu a {
    color: #222;
    text-decoration: none;
    transition: color 0.2s;
}

.nav-menu a:hover {
    color: var(--blue);
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

.login-dropdown {
    position: relative;
}

.login-dropdown-content {
    display: none;
    position: absolute;
    right: 0;
    background-color: white;
    min-width: 160px;
    box-shadow: 0px 8px 16px 0px rgba(0, 0, 0, 0.2);
    z-index: 1;
    border-radius: 8px;
    overflow: hidden;
}

.login-dropdown-content a {
    color: black;
    padding: 12px 16px;
    text-decoration: none;
    display: block;
    font-size: 14px;
}

.login-dropdown-content a:hover {
    background-color: #f1f1f1;
}

.login-dropdown:hover .login-dropdown-content {
    display: block;
}

.login-btn {
    background: none;
    border: none;
    cursor: pointer;
    font-family: inherit;
    font-size: 15px;
    font-weight: 500;
    padding: 8px 16px;
}

.login-btn:hover {
    color: var(--blue);
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, #0e5aa0 0%, #4ade80 100%);
    color: white;
    padding: 140px 40px 100px;
    position: relative;
    overflow: hidden;
}

.hero-content {
    max-width: 1280px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
}

.hero-text h1 {
    font-size: 58px;
    line-height: 1.05;
    font-weight: 600;
    letter-spacing: -2px;
    margin-bottom: 24px;
}

.logo-container {
    position: relative;
    display: inline-block;
}

.bubble {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 520px;
    height: 520px;
    background: rgba(255, 255, 255, 0.90);
    border-radius: 50%;
    z-index: 1;
    filter: blur(65px);
}

.logo-img {
    position: relative;
    z-index: 2;
    width: 460px;
    filter: drop-shadow(0 30px 60px rgba(0, 0, 0, 0.35));
}

/* Services Section */
.service-card {
    background: white;
    border-radius: 24px;
    padding: 40px 32px;
    box-shadow: 0 12px 25px -4px rgba(0, 0, 0, 0.09);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    height: 100%;
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: inherit;
}

.service-card:hover {
    transform: translateY(-12px);
    box-shadow: 0 30px 60px -12px rgba(14, 90, 160, 0.32);
}

.service-icon {
    font-size: 42px;
    margin-bottom: 24px;
    height: 64px;
}

.service-card h3 {
    font-size: 26px;
    margin-bottom: 16px;
    font-weight: 600;
}

.service-card p {
    flex-grow: 1;
    margin-bottom: 20px;
}

.service-link {
    margin-top: auto;
    color: #0e5aa0;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.service-link:hover {
    gap: 12px;
}

/* Contact Section */
.contact-card {
    background: white;
    border-radius: 24px;
    padding: 40px 32px;
    text-align: center;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.10);
    transition: all 0.3s ease;
}

.contact-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 30px 60px -12px rgba(14, 90, 160, 0.32);
}

.reveal-btn {
    color: #0e5aa0;
    text-decoration: underline;
    cursor: pointer;
    font-weight: 600;
    font-size: 15px;
}

.reveal-content {
    display: none;
}

/* Footer */
.footer {
    background: #0e5aa0;
    color: white;
    padding: 40px 20px 35px;
    box-shadow: 0 -12px 30px rgba(0, 0, 0, 0.22);
    position: relative;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 50px;
    max-width: 1280px;
    margin: 0 auto;
}

.footer a {
    color: white;
    opacity: 1;
    text-decoration: none;
    transition: all 0.3s ease;
}

.footer a:hover {
    color: #4ade80;
    text-decoration: underline;
    text-shadow: 0 0 12px rgba(74, 222, 128, 0.7);
}

/* Floating WhatsApp Button */
.whatsapp-float {
    position: fixed;
    bottom: 25px;
    right: 25px;
    background: #25D366;
    color: white;
    width: 62px;
    height: 62px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.4);
    z-index: 1000;
    text-decoration: none;
    transition: all 0.3s ease;
}

.whatsapp-float:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.5);
}

/* --- Login Page Specific Styles (Admin & Client) --- */

/* Common layout for centered login pages */
.centered-page-layout {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    margin: 0; /* Ensure no default body margin interferes */
}

/* Admin Login Box */
.admin-login-box {
    background: white;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 400px;
}

.admin-login-box input {
    width: 100%;
    padding: 12px;
    margin: 10px 0;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 16px;
}

.admin-login-box button {
    width: 100%;
    padding: 14px;
    background: #0e5aa0;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    cursor: pointer;
    margin-top: 10px;
}

.admin-login-box .error {
    color: #e11d48;
    text-align: center;
    margin: 10px 0;
}

/* Client Login Container */
.client-login-container {
    max-width: 900px;
    width: 100%;
    margin: 40px auto;
    display: grid;
    grid-template-columns: 1fr 460px;
    gap: 80px;
    align-items: center;
    padding: 0 20px;
}
.client-login-logo {
    height: 60px;
    margin-bottom: 20px;
}

.client-login-text h2 {
    font-size: 42px;
    font-weight: 600;
    letter-spacing: -1px;
}

.client-login-text p {
    font-size: 21px;
    color: #555;
    margin-top: 16px;
    max-width: 520px;
    margin-left: auto; /* Center the paragraph when text-align is center */
    margin-right: auto; /* Center the paragraph when text-align is center */
}

.client-login-text .btn {
    margin-top: 40px;
    min-width: 220px;
    font-size: 15px;
}

.client-login-form-card {
    background: #fff;
    border-radius: 28px;
    padding: 48px 40px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
}

.client-login-form-card label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    margin-bottom: 8px;
    color: #444;
}

.client-login-form-card input {
    width: 100%;
    padding: 18px 24px;
    border: 1px solid #ddd;
    border-radius: 9999px;
    font-size: 16px;
}

.client-login-form-card .btn {
    width: 100%;
}

.client-login-form-card .error-message {
    color: #e11d48;
    background: #fee2e2;
    padding: 12px;
    border-radius: 16px;
    margin-bottom: 20px;
    font-size: 14px;
}

/* Responsive adjustments for Client Login */
@media (max-width: 768px) {
    .client-login-container {
        grid-template-columns: 1fr;
        gap: 40px;
        padding: 20px;
    }
    .client-login-text h2 {
        font-size: 36px;
    }
    .client-login-text p {
        font-size: 18px;
        max-width: none;
    }
    .client-login-text .btn {
        margin-top: 30px;
    }
}

@media (max-width: 480px) {
    .client-login-form-card {
        padding: 30px 25px;
    }
    .client-login-text h2 {
        font-size: 30px;
    }
    .client-login-text p {
        font-size: 16px;
    }
}

/* --- Forgot Password Page Specific Styles --- */

.forgot-password-hero {
    background: linear-gradient(135deg, #0e5aa0 0%, #4ade80 100%);
    color: white;
    padding: 110px 40px 90px;
    align-items: center;
    justify-content: center;
}

.forgot-password-box {
    background: rgba(255, 255, 255, 0.22);
    backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: 24px;
    padding: 50px 40px;
    max-width: 480px;
    width: 100%;
    margin: 0 auto;
}

.forgot-password-box input {
    width: 100%;
    padding: 18px 24px;
    border: 1px solid rgba(255, 255, 255, 0.5);
    border-radius: 9999px;
    font-size: 16px;
    background: rgba(255, 255, 255, 0.15);
    color: white;
}

.forgot-password-box input::placeholder {
    color: rgba(255, 255, 255, 0.7);
    opacity: 1; /* Firefox */
}

.forgot-password-box .form-action-wrapper {
    display: flex;
    justify-content: center;
}

/* --- CIF Process Page Specific Styles (Success & Error) --- */

/* A4 Page Container */
.a4-page-document { /* Unified class for A4 page layout */
    width: 210mm; /* Standard A4 width */
    min-height: 297mm;
    padding: 20mm 15mm 50mm 15mm;
    margin: 20px auto;
    background: white;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.15);
    font-size: 11pt;
    line-height: 1.55;
    color: #222;
    box-sizing: border-box;
    position: relative;
    flex-shrink: 0; /* Prevent it from shrinking in a flex container */
    overflow: hidden;
}

/* Header */
.cif-header {
    text-align: center;
    margin-bottom: 25px;
    border-bottom: 3px solid var(--blue);
    padding-bottom: 15px;
}

.cif-logo {
    display: block;
    margin: 0 auto 12px;
    max-width: 220px;
}

.cif-company-details {
    font-size: 10pt;
    line-height: 1.4;
    color: #444;
    margin: 0;
}

/* Error Page Styles */
.cif-error-h1 {
    color: #e11d48;
    font-size: 24pt;
    margin: 8px 0 4px;
    font-weight: bold;
    letter-spacing: 1px;
    text-align: center; /* Added for consistency */
}

.cif-error-box {
    background: #fee2e2;
    border: 3px solid #e11d48;
    padding: 40px;
    margin: 30px 0;
    text-align: center;
    border-radius: 8px;
}

.cif-error-box h2 {
    color: #e11d48;
    margin-bottom: 15px; /* Added for spacing */
}

/* Success Page Styles */
.cif-success-h1 {
    color: var(--blue);
    font-size: 24pt;
    margin: 8px 0 4px;
    font-weight: bold;
    letter-spacing: 1px;
    text-align: center; /* Added for consistency */
}

.cif-success-box {
    background: #e6f7e6;
    border: 3px solid var(--blue);
    padding: 30px;
    margin: 30px 0;
    text-align: center;
    border-radius: 8px;
}

.cif-success-box h2 {
    color: var(--blue);
    margin: 0 0 15px; /* Added for spacing */
}

/* Common Button Style for CIF Process Pages */
.cif-button {
    background: var(--blue);
    color: white;
    padding: 14px 40px;
    text-decoration: none;
    border-radius: 4px;
    font-weight: bold;
    display: inline-block; /* To allow padding and margin */
    margin-top: 20px; /* Added for spacing */
}

/* Footer */
.cif-footer {
    position: absolute;
    bottom: 18mm;
    left: 15mm;
    right: 15mm;
    text-align: center;
    font-size: 9pt;
    color: #555;
    border-top: 1px solid #ddd;
    padding-top: 8px;
    line-height: 1.3;
}

/* Global A4 page print styles */
@media print {
    @page {
        size: A4 portrait;
        margin: 0;
    }
    body {
        background: white !important;
    }
    .a4-page-document {
        margin: 0;
        box-shadow: none;
    }
}

/* --- CIF Form Page (cif.php) --- */
.cif-page-body {
    background: #f4f4f4;
    font-family: Arial, Helvetica, sans-serif;
    /* Ensure body expands to fill viewport and supports sticky footer */
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.cif-form-container h1 {
    color: var(--blue);
    font-size: 24pt;
    margin: 8px 0 4px;
    font-weight: bold;
    letter-spacing: 1px;
}

.cif-form-container h2 {
    color: var(--blue);
    font-size: 13pt;
    border-bottom: 2px solid #e5e7eb;
    padding-bottom: 6px;
    margin: 28px 0 12px;
}

.cif-form-group {
    margin-bottom: 18px;
}

.cif-form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
    color: #333;
}

.cif-form-group input[type="text"],
.cif-form-group input[type="email"],
.cif-form-group input[type="tel"],
.cif-form-group input[type="password"],
.cif-form-group input[type="date"],
.cif-form-group select,
.cif-form-group textarea {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid var(--blue);
    border-radius: 4px;
    font-size: 11pt;
    box-sizing: border-box;
}

.cif-radio-group {
    display: flex;
    gap: 20px;
    margin-bottom: 12px;
}

.cif-checkbox-group label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: normal;
    margin-bottom: 8px;
}

.cif-signature-box {
    border: 2px dashed var(--blue);
    padding: 25px;
    text-align: center;
    margin: 20px 0;
    background: #f8f9fa;
    font-size: 11pt;
}

.cif-note-box {
    background: #f8f9fa;
    border-left: 5px solid var(--blue);
    padding: 12px 15px;
    margin: 20px 0;
    font-size: 10pt;
}

.cif-captcha-box {
    background: #f8f9fa;
    border: 2px solid var(--blue);
    padding: 20px;
    border-radius: 8px;
    margin: 30px 0;
    text-align: center;
}

.cif-form-container .effective-date {
    text-align: right;
    font-size: 11pt;
    color: #444;
    margin-bottom: 20px;
}

.cif-form-container .section-number {
    display: inline-block;
    width: 28px;
    font-weight: bold;
    color: var(--blue);
}

/* Specific styles for cif.php elements */
.cif-effective-date-input {
    border: none;
    background: transparent;
    font-weight: bold;
    width: auto;
    display: inline-block; /* To allow width:auto and respect parent text-align */
}

.cif-captcha-input {
    width: 240px;
    font-size: 14pt;
    text-align: center;
    padding: 12px;
    display: inline-block; /* To respect text-align: center from parent */
}

.cif-submit-button {
    background: var(--blue);
    color: white;
    padding: 14px 50px;
    border: none;
    font-size: 13pt;
    cursor: pointer;
    border-radius: 4px;
    display: inline-block; /* To allow centering via parent text-align */
}
