/* Sivoko Group Portal - Theme Steel CSS stylesheet */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;600;700&family=Roboto:wght@300;400;500;700&display=swap');

:root {
    --stl-primary: #1d406b;       /* Solid Steel Blue */
    --stl-secondary: #e65c00;     /* Industrial Orange */
    --stl-bg: #f4f6f8;            /* Light Steel Grey */
    --stl-text: #1a1e24;          /* Dark slate */
    --stl-text-muted: #64748b;
    --stl-border: #cbd5e1;
    --stl-border-light: #e2e8f0;
    --stl-success: #4CAF50;
    --stl-error: #f44336;
    --stl-card-bg: #ffffff;
    --stl-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --stl-shadow-lg: 0 10px 40px rgba(0, 0, 0, 0.08);
    --font-head: 'Montserrat', sans-serif;
    --font-body: 'Roboto', sans-serif;
    --transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

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

body.inquiry-body {
    font-family: var(--font-body);
    background-color: var(--stl-bg);
    color: var(--stl-text);
    line-height: 1.5;
    padding-top: 50px;
    padding-bottom: 60px;
    overflow-x: hidden;
}

.inquiry-container {
    max-width: 900px;
    margin: 0 auto;
    background: var(--stl-card-bg);
    border-radius: 12px;
    box-shadow: var(--stl-shadow-lg);
    overflow: hidden;
    position: relative;
}

/* Header style outside card */
.site-header {
    text-align: center;
    margin-bottom: 2rem;
}

.site-header img {
    height: 70px;
    width: auto;
    object-fit: contain;
    border-radius: 8px;
    margin-bottom: 0.5rem;
}

.site-header h1 {
    font-family: var(--font-head);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--stl-primary);
    letter-spacing: 1px;
    text-transform: uppercase;
}

/* --- Progress Stepper --- */
.form-stepper {
    display: flex;
    justify-content: space-between;
    background: var(--stl-primary);
    padding: 1.25rem 2rem;
    color: rgba(255, 255, 255, 0.5);
    position: sticky;
    top: 0;
    z-index: 10;
}

.step {
    flex: 1;
    text-align: center;
    position: relative;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    transition: var(--transition);
}

.step::after {
    content: '';
    position: absolute;
    top: 12px;
    left: 50%;
    width: 100%;
    height: 2px;
    background: rgba(255, 255, 255, 0.2);
    z-index: 1;
}

.step:last-child::after {
    display: none;
}

.step-circle {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: bold;
    color: white;
    position: relative;
    z-index: 2;
    transition: var(--transition);
}

.step.active {
    color: var(--stl-card-bg);
}

.step.active .step-circle {
    background: var(--stl-secondary);
    box-shadow: 0 0 10px var(--stl-secondary);
}

.step.completed {
    color: var(--stl-card-bg);
}

.step.completed .step-circle {
    background: var(--stl-success);
}

/* --- Form Sections --- */
.form-section {
    display: none;
    padding: 2.5rem 3.5rem;
    animation: fadeIn 0.4s ease-out;
}

.form-section.active {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.section-title {
    font-family: var(--font-head);
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--stl-primary);
    margin-bottom: 0.5rem;
}

.section-desc {
    color: var(--stl-text-muted);
    font-size: 0.95rem;
    margin-bottom: 2rem;
}

/* Form inputs & grids */
.form-row {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.form-group {
    flex: 1;
    min-width: 0; /* Critical layout fix: prevents elements from breaking flex boundaries */
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-label {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--stl-text);
}

.form-control {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid var(--stl-border);
    border-radius: 0.5rem;
    font-size: 1rem;
    font-family: var(--font-body);
    color: var(--stl-text);
    background-color: var(--stl-bg);
    transition: var(--transition);
    outline: none;
    box-sizing: border-box;
}

.form-control:focus {
    border-color: var(--stl-secondary);
    background-color: var(--stl-card-bg);
    box-shadow: 0 0 0 3px rgba(230, 92, 0, 0.15);
}

.tooltip-icon {
    display: inline-flex;
    width: 1rem;
    height: 1rem;
    border-radius: 50%;
    background-color: var(--stl-border);
    font-size: 0.75rem;
    align-items: center;
    justify-content: center;
    color: var(--stl-text-muted);
    cursor: help;
    margin-left: 0.25rem;
}

/* Visual multi-select grid cards */
.selection-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.selection-card {
    border: 2px solid var(--stl-border-light);
    border-radius: 0.75rem;
    padding: 1.5rem;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    background-color: var(--stl-bg);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    user-select: none;
}

.selection-card i {
    font-size: 2rem;
    color: var(--stl-text-muted);
    transition: var(--transition);
}

.selection-card span {
    font-size: 1rem;
    font-weight: 600;
    color: var(--stl-text);
}

.selection-card:hover {
    transform: translateY(-3px);
    border-color: var(--stl-border);
    box-shadow: var(--stl-shadow);
}

.selection-card.selected {
    border-color: var(--stl-secondary);
    background-color: #fff6f0;
    box-shadow: 0 0 0 3px rgba(230, 92, 0, 0.1);
}

.selection-card.selected i {
    color: var(--stl-secondary);
}

/* Conditional Geometry Layout */
.conditional-wrapper {
    display: none;
    border: 1px dashed var(--stl-border);
    border-radius: 0.75rem;
    padding: 1.75rem;
    margin-top: 1.5rem;
    background-color: #fafbfd;
    animation: fadeIn 0.3s ease-out;
}

.conditional-wrapper.show {
    display: block;
}

/* Inline SVG diagrams */
.conditional-wrapper svg {
    display: block;
    margin: 1.5rem auto;
    border: 1px solid var(--stl-border-light);
    background: white;
}

/* Buttons */
.form-actions {
    display: flex;
    justify-content: space-between;
    margin-top: 2.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--stl-border-light);
}

.btn {
    padding: 0.75rem 1.75rem;
    border: none;
    border-radius: 0.5rem;
    font-size: 1rem;
    font-weight: 600;
    font-family: var(--font-head);
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

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

.btn-primary:hover {
    background-color: #142d4c;
    box-shadow: 0 4px 10px rgba(29, 64, 107, 0.3);
}

.btn-secondary {
    background-color: var(--stl-border-light);
    color: var(--stl-text);
}

.btn-secondary:hover {
    background-color: var(--stl-border);
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* File zone uploads */
.file-upload-zone {
    border: 2px dashed var(--stl-border);
    border-radius: 0.75rem;
    padding: 2.5rem;
    text-align: center;
    cursor: pointer;
    background-color: var(--stl-bg);
    transition: var(--transition);
    margin-bottom: 1.5rem;
}

.file-upload-zone:hover {
    border-color: var(--stl-secondary);
    background-color: #fff6f0;
}

.file-upload-zone i {
    font-size: 2.5rem;
    color: var(--stl-text-muted);
    margin-bottom: 1rem;
}

.file-upload-zone h4 {
    font-family: var(--font-head);
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.file-input {
    display: none;
}

.file-preview-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: var(--stl-bg);
    padding: 0.75rem 1.25rem;
    border-radius: 0.5rem;
    margin-bottom: 0.75rem;
    border: 1px solid var(--stl-border-light);
}

/* Summary table styling */
.summary-section {
    margin-bottom: 2rem;
    border: 1px solid var(--stl-border-light);
    border-radius: 0.5rem;
    overflow: hidden;
}

.summary-header {
    background-color: var(--stl-bg);
    padding: 1rem 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--stl-border-light);
}

.edit-link {
    color: var(--stl-secondary);
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    text-decoration: none;
}

.edit-link:hover {
    text-decoration: underline;
}

.summary-table {
    width: 100%;
    border-collapse: collapse;
}

.summary-table th,
.summary-table td {
    padding: 0.75rem 1.5rem;
    text-align: left;
    border-bottom: 1px solid var(--stl-border-light);
    font-size: 0.95rem;
}

.summary-table th {
    font-weight: 600;
    color: var(--stl-text-muted);
    width: 35%;
}

.summary-table td {
    color: var(--stl-text);
    font-weight: 500;
}

.mt-4 {
    margin-top: 1.5rem;
}

/* Modals overlays */
#login-modal, #otp-modal {
    display: none; 
    position: fixed; 
    top: 0; 
    left: 0; 
    width: 100%; 
    height: 100%; 
    background: rgba(15, 17, 21, 0.85); 
    backdrop-filter: blur(5px);
    z-index: 1000; 
    align-items: center; 
    justify-content: center;
}

.modal-card {
    background: var(--stl-card-bg); 
    padding: 2.5rem; 
    border-radius: 12px; 
    max-width: 420px; 
    width: 90%; 
    text-align: center; 
    position: relative;
    box-shadow: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
    animation: modalSlide 0.3s ease-out;
}

@keyframes modalSlide {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.text-center {
    text-align: center;
}

/* Responsive styles */
@media (max-width: 900px) {
    body.inquiry-body {
        padding-top: 20px;
    }
    .form-section {
        padding: 2rem 1.5rem;
    }
    .form-row {
        flex-direction: column;
        gap: 1rem;
        margin-bottom: 1rem;
    }
    .form-stepper {
        padding: 1rem;
    }
    .step span {
        display: none;
    }
    .step::after {
        top: 12px;
    }
}


/* Public lead-first flow */
.public-flow-kicker {
    display:inline-block; margin-bottom:0.8rem; font-size:0.78rem; font-weight:800;
    letter-spacing:0.08em; color:var(--stl-secondary); text-transform:uppercase;
}
.lead-honeypot { position:absolute !important; left:-9999px !important; opacity:0 !important; height:1px !important; width:1px !important; }
.lead-submit-message { margin-top:1rem; font-size:0.9rem; font-weight:600; }
.lead-submit-message.error { color:#ef4444; }
.advisory-success {
    display:inline-flex; align-items:center; gap:0.5rem; padding:0.6rem 0.9rem;
    border-radius:999px; background:#ecfdf5; color:#047857; font-weight:700; margin-bottom:1rem;
}
.advisory-card {
    border:1px solid var(--stl-border); border-left:4px solid var(--stl-secondary);
    background:var(--stl-card-bg); border-radius:10px; padding:1.35rem 1.5rem;
}
.advisory-card h3 { margin:0 0 0.65rem; color:var(--stl-primary); }
.advisory-card p { margin:0.6rem 0; color:var(--stl-text); line-height:1.65; }
.advisory-actions { display:flex; flex-wrap:wrap; gap:0.85rem; align-items:center; }
.logged-in-note { width:100%; margin:0 0 0.25rem; color:var(--stl-text-muted); font-weight:600; }
@media (max-width: 680px) { .advisory-actions { flex-direction:column; align-items:stretch; } .advisory-actions .btn { width:100%; justify-content:center; } }
