:root {
    /* World-Class Palette - Reliable & Safe */
    --primary-color: #0F172A; /* Slate 900 - Professional, Strong */
    --primary-hover: #1E293B; /* Slate 800 */
    
    --accent-color: #0284C7; /* Sky 600 - Optimistic blue */
    --accent-light: #F0F9FF; /* Sky 50 */
    
    --success-color: #059669; /* Emerald 600 - Action/WhatsApp */
    --success-hover: #047857; /* Emerald 700 */
    
    --whatsapp-color: #25D366;
    
    --bg-page: #F8FAFC; /* Slate 50 - Calm background */
    --bg-card: #FFFFFF;
    
    --text-main: #334155; /* Slate 700 - Softer black for reading */
    --text-muted: #64748B; /* Slate 500 */
    
    --border-color: #E2E8F0; /* Slate 200 */
    --border-focus: #0F172A;
    
    --shadow-card: 0 10px 15px -3px rgba(0, 0, 0, 0.05), 0 4px 6px -2px rgba(0, 0, 0, 0.025);
    --shadow-input: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-btn: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    
    --radius-lg: 20px;
    --radius-md: 12px;
    --radius-sm: 8px;
    
    --font-family: 'Inter', system-ui, -apple-system, sans-serif;
}

* {
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: var(--font-family);
    background-color: var(--bg-page);
    color: var(--text-main);
    margin: 0;
    padding: 20px;
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Main Container */
.container {
    background: var(--bg-card);
    padding: 0;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
    width: 100%;
    max-width: 600px;
    margin-top: 20px;
    margin-bottom: 60px;
    overflow: hidden;
}

/* Microcopy Helper Class */
.microcopy {
    font-size: 13px;
    color: var(--text-muted);
    text-align: center;
    margin-top: 8px;
    font-weight: 400;
}

/* === HERO SECTION === */
.hero-section {
    padding: 48px 32px;
    text-align: center;
    background-color: #fff;
    border-bottom: 1px solid var(--border-color);
}

h1 {
    font-size: 32px;
    color: var(--primary-color);
    margin-bottom: 16px;
    margin-top: 0;
    font-weight: 800;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

.subtitle {
    color: var(--text-muted);
    margin-bottom: 32px;
    font-size: 18px;
    line-height: 1.5;
    font-weight: 400;
}

.hero-benefits {
    list-style: none;
    padding: 0;
    margin: 0 0 40px 0;
    text-align: left;
    display: inline-block;
}

.hero-benefits li {
    margin-bottom: 12px;
    font-size: 16px;
    color: var(--text-main);
    display: flex;
    align-items: flex-start;
    gap: 8px;
}

.btn-primary-action {
    background-color: var(--primary-color);
    color: white;
    font-size: 18px;
    padding: 18px 24px;
    border-radius: var(--radius-md);
    border: none;
    width: 100%;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: var(--shadow-btn);
}

.btn-primary-action:hover, .btn-primary-action:focus {
    background-color: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    outline: none;
}

.btn-primary-action:active {
    transform: translateY(0);
}

/* === SERVICES SECTION === */
.services-section {
    padding: 40px 32px;
    background-color: #F9FAFB;
}

h3 {
    color: var(--primary-color);
    font-size: 22px;
    margin-bottom: 24px;
    margin-top: 0;
    font-weight: 700;
    letter-spacing: -0.02em;
    text-align: center;
}

.services-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.service-item {
    background: white;
    padding: 20px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    text-align: center;
    font-size: 14px;
    transition: transform 0.2s ease;
}

.service-item:hover {
    transform: translateY(-2px);
    border-color: var(--accent-color);
}

.service-item strong {
    display: block;
    font-size: 16px;
    margin-bottom: 6px;
    color: var(--primary-color);
}

.service-item small {
    color: var(--text-muted);
    line-height: 1.3;
    display: block;
    font-size: 13px;
}

/* === PRICING SECTION === */
.pricing-section {
    padding: 40px 32px;
    background-color: white;
    border-bottom: 1px solid var(--border-color);
}

.pricing-card {
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 24px;
    margin-bottom: 20px;
    background-color: #fff;
    transition: all 0.2s ease;
}

.pricing-card:hover {
    border-color: var(--text-muted);
}

.pricing-card:last-child {
    margin-bottom: 0;
}

.pricing-card.highlight {
    border: 2px solid var(--accent-color);
    background-color: var(--accent-light);
}

.pricing-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 12px;
    flex-wrap: wrap;
    gap: 8px;
}

.pricing-header h4 {
    margin: 0;
    font-size: 18px;
    color: var(--primary-color);
    font-weight: 700;
}

.pricing-header .price {
    font-size: 18px;
    font-weight: 700;
    color: var(--success-color);
}

.pricing-card p {
    margin: 0 0 10px 0;
    font-size: 15px;
    color: var(--text-main);
    line-height: 1.5;
}

.pricing-subtext {
    font-size: 14px;
    color: var(--text-muted) !important;
}

.pricing-hook {
    margin-top: 16px !important;
    color: var(--primary-color) !important;
    font-weight: 600;
    font-size: 14px !important;
    background: rgba(255,255,255,0.5);
    padding: 8px;
    border-radius: 6px;
}

/* === STEPS SECTION === */
.steps-section {
    padding: 40px 32px;
    background-color: white;
    border-bottom: 1px solid var(--border-color);
}

.step-card {
    display: flex;
    align-items: flex-start;
    margin-bottom: 24px;
    gap: 16px;
}

.step-card:last-child {
    margin-bottom: 0;
}

.step-number {
    background-color: var(--accent-light);
    color: var(--accent-color);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    flex-shrink: 0;
    font-size: 18px;
}

.step-card p {
    margin: 0;
    font-size: 16px;
    color: var(--text-muted);
    margin-top: 2px;
}

.step-card strong {
    color: var(--primary-color);
    display: block;
    margin-bottom: 4px;
    font-size: 17px;
}

/* === TOOL / FORM SECTION === */
.tool-section {
    padding: 40px 32px;
    background-color: #F1F5F9; /* Light Slate */
}

.tool-intro {
    text-align: center;
    font-size: 16px;
    color: var(--text-muted);
    margin-bottom: 24px;
    margin-top: -10px;
    line-height: 1.5;
}

.form-wrapper {
    background: white;
    padding: 24px;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-card);
    margin-bottom: 20px;
}

.form-group {
    margin-bottom: 24px;
}

label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--primary-color);
    font-size: 15px;
}

select, input[type="text"], input[type="date"], textarea {
    width: 100%;
    padding: 16px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 16px;
    font-family: var(--font-family);
    background-color: #fff;
    color: var(--text-main);
    box-shadow: var(--shadow-input);
    transition: border-color 0.2s ease;
    appearance: none;
}

/* Select Custom Arrow */
select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%2364748B' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    padding-right: 48px;
}

select:focus, input:focus, textarea:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px var(--accent-light);
}

textarea {
    resize: vertical;
    min-height: 150px;
    background-color: #FAFAFA;
    line-height: 1.5;
}

/* Checkbox */
.checkbox-wrapper {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    margin-bottom: 20px;
    cursor: pointer;
    padding: 8px;
    background: #F8FAFC;
    border-radius: var(--radius-sm);
}

.checkbox-wrapper input[type="checkbox"] {
    margin-top: 3px;
    width: 22px;
    height: 22px;
    flex-shrink: 0;
    cursor: pointer;
    accent-color: var(--success-color);
}

.checkbox-wrapper label {
    margin-bottom: 0;
    font-weight: 400;
    color: var(--text-main);
    font-size: 15px;
    line-height: 1.4;
    cursor: pointer;
}

/* Buttons */
button {
    width: 100%;
    padding: 18px;
    border: none;
    border-radius: var(--radius-md);
    font-size: 17px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
    overflow: hidden;
}

#btnHabeas, #btnGenerar {
    background-color: var(--primary-color);
    color: white;
    margin-top: 0;
    box-shadow: var(--shadow-btn);
}

#btnHabeas:hover, #btnGenerar:hover {
    background-color: var(--primary-hover);
    transform: translateY(-1px);
}

#btnCopiar {
    background-color: var(--success-color);
    color: white;
    margin-top: 12px;
    box-shadow: var(--shadow-btn);
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
}

#btnCopiar:hover {
    background-color: var(--success-hover);
    transform: translateY(-1px);
}

#btnEditar {
    background-color: transparent;
    color: var(--text-muted);
    border: 1px solid var(--border-color);
    margin-top: 16px;
    padding: 14px;
    font-size: 15px;
}

#btnEditar:hover {
    color: var(--text-main);
    border-color: var(--text-muted);
    background-color: #fff;
}

#whatsLink button {
    background-color: var(--whatsapp-color);
    color: white;
    margin-top: 20px;
}

/* Footer */
.footer-section {
    padding: 40px 32px;
    text-align: center;
    background-color: white;
    border-top: 1px solid var(--border-color);
}

.footer-section p {
    color: var(--text-muted);
    font-size: 14px;
    margin: 0 0 12px 0;
    line-height: 1.5;
    max-width: 400px;
    margin-left: auto;
    margin-right: auto;
}

.footer-brand {
    font-weight: 700;
    color: var(--primary-color) !important;
    margin-top: 24px !important;
}

/* Animations */
.hidden { display: none !important; }

.section { animation: slideUpFade 0.5s cubic-bezier(0.2, 0.8, 0.2, 1); }

@keyframes slideUpFade {
    from { opacity: 0; transform: translateY(15px); }
    to { opacity: 1; transform: translateY(0); }
}

.success-message {
    background-color: #ECFDF5;
    color: #047857;
    padding: 16px;
    border-radius: var(--radius-md);
    margin-top: 24px;
    text-align: center;
    font-weight: 600;
    border: 1px solid #A7F3D0;
    animation: slideUpFade 0.3s ease;
}

/* Mobile Tweaks */
@media (max-width: 640px) {
    body {
        padding: 0;
        background-color: white;
    }
    
    .container {
        box-shadow: none;
        border: none;
        border-radius: 0;
        margin: 0;
        max-width: 100%;
        margin-bottom: 0;
    }
    
    .hero-section { padding: 40px 20px; }
    .services-section { padding: 32px 20px; }
    .pricing-section { padding: 32px 20px; }
    .steps-section { padding: 32px 20px; }
    .tool-section { padding: 32px 16px; }
    .footer-section { padding: 40px 20px; }
    
    h1 { font-size: 28px; }
    
    .services-grid {
        grid-template-columns: 1fr;
    }
    
    button { padding: 20px; }
    
    .pricing-card { padding: 20px; }
}