/*
  Professional Responsiveness & Layout Layer
*/

:root {
    --container-px-mobile: 1.25rem;
    --container-px-desktop: 2rem;
    --brand-green: #16a34a;
    --brand-orange: #f97315;
    --brand-orange-hover: #ea580c;
}

/* Typography Scaling (Fluid H1-H4) */
h1 { font-size: clamp(1.875rem, 5vw, 3rem); line-height: 1.1; }
h2 { font-size: clamp(1.5rem, 4vw, 2.25rem); line-height: 1.2; }
h3 { font-size: clamp(1.25rem, 3vw, 1.75rem); line-height: 1.3; }
h4 { font-size: clamp(1.125rem, 2vw, 1.25rem); line-height: 1.4; }

h1, h2, h3, h4 {
    letter-spacing: -0.02em;
    font-weight: 800;
}

/* Responsive Containers */
.container {
    width: 100%;
    margin-right: auto;
    margin-left: auto;
    padding-right: var(--container-px-mobile);
    padding-left: var(--container-px-mobile);
}

@media (min-width: 768px) {
    .container {
        padding-right: var(--container-px-desktop);
        padding-left: var(--container-px-desktop);
        max-width: 1280px;
    }
}

/* Form Responsiveness */
@media (max-width: 767px) {
    .form-group-grid {
        display: grid;
        grid-template-columns: 1fr !important;
        gap: 1rem;
    }

    .btn-action, .form-input {
        width: 100% !important;
    }
}

/* Salary Tax Toggle Fix (Stacking on narrow screens) */
@media (max-width: 400px) {
    .tax-type-toggle {
        flex-direction: column !important;
        gap: 0.5rem;
    }
    .tax-type-toggle button {
        width: 100%;
        border-radius: 0.5rem !important; /* Remove grouped rounding */
    }
}

/* Professional Table Responsiveness */
.table-responsive {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: 0.75rem;
    border: 1px solid #e2e8f0;
    margin-bottom: 1.5rem;
}

.table-responsive::-webkit-scrollbar {
    height: 4px;
}

.table-responsive::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 10px;
}

/* Ads Section Safety */
.ad-slot-container {
    max-width: 100%;
    overflow: hidden;
    margin-bottom: 2rem;
}

/* Rest of existing styles */
html {
    scroll-behavior: smooth;
    background-color: #f8fafc;
}

body {
    font-family: 'Inter', sans-serif;
    color: #1e293b;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

main {
    flex: 1;
}

.ad-slot {
    background-color: #e2e8f0;
    border: 1px dashed #cbd5e1;
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #64748b;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    margin: 1.5rem 0;
}

.ad-slot-leaderboard { width: 100%; height: 90px; }
.ad-slot-rectangle { width: 100%; height: 250px; }
.ad-slot-responsive { width: 100%; min-height: 200px; }

.form-input {
    border: 1px solid #e2e8f0;
    transition: all 0.2s ease-in-out;
    background-color: #ffffff;
    border-radius: 0.5rem;
    padding: 0.875rem 1rem;
}

.form-input:focus {
    outline: none;
    border-color: var(--brand-green);
    box-shadow: 0 0 0 3px rgba(22, 163, 74, 0.15);
}

.app-card {
    background: #ffffff;
    border-radius: 1rem;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.05), 0 4px 6px -2px rgba(0, 0, 0, 0.025);
    border: 1px solid #f1f5f9;
    transition: transform 0.2s, box-shadow 0.2s;
}

.app-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.05), 0 10px 10px -5px rgba(0, 0, 0, 0.02);
}

.btn-action {
    background-color: var(--brand-orange);
    color: white;
    font-weight: 700;
    border-radius: 0.5rem;
    border: none;
    cursor: pointer;
    transition: background-color 0.2s;
    text-align: center;
    width: 100%;
    box-shadow: 0 4px 6px -1px rgba(249, 115, 21, 0.2);
    padding: 0.75rem 1.5rem;
}

.btn-action:hover { background-color: var(--brand-orange-hover); }

.btn-secondary {
    background-color: transparent;
    color: var(--brand-green);
    font-weight: 700;
    border: 2px solid var(--brand-green);
    border-radius: 0.5rem;
    cursor: pointer;
    transition: all 0.2s;
    padding: 0.5rem 1rem;
}

.btn-secondary:hover {
    background-color: var(--brand-green);
    color: white;
}

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

.animate-fade-in {
    animation: fadeIn 0.4s ease-out forwards;
}
/* Summernote table Styling */
.content-area table {
    width: 100%;
    border-collapse: collapse;
    margin: 1rem 0;
}

.content-area table td,
.content-area table th {
    border: 1px solid #ddd;
    padding: 8px 12px;
    text-align: left;
}

.content-area table th {
    background-color: #f5f5f5;
    font-weight: bold;
}
