/* Reset and base */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    color: #1B2A3A;
    background-color: #F5F7FA;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Header */
.site-header {
    background-color: #1B3A5C;
    color: #FFFFFF;
    padding: 0.75rem 1.5rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    color: #FFFFFF;
    font-weight: 700;
    font-size: 1.2rem;
}

.logo-text {
    letter-spacing: -0.02em;
}

.main-nav {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.main-nav a {
    color: #D0DFF0;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    transition: color 0.2s;
}

.main-nav a:hover,
.main-nav a:focus {
    color: #FFB347;
    text-decoration: underline;
}

/* Main content */
main {
    flex: 1;
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
    padding: 1.5rem 1.5rem 3rem;
}

/* Hero */
.hero {
    text-align: center;
    padding: 2rem 0 1.5rem;
}

.hero h1 {
    font-size: 2rem;
    font-weight: 800;
    color: #1B3A5C;
    margin-bottom: 0.75rem;
    letter-spacing: -0.03em;
    line-height: 1.25;
}

.hero-subtitle {
    font-size: 1.1rem;
    color: #4A5568;
    max-width: 650px;
    margin: 0 auto;
}

/* Section titles */
.section-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1B3A5C;
    margin-bottom: 1.25rem;
    padding-bottom: 0.5rem;
    border-bottom: 3px solid #FFB347;
    display: inline-block;
}

/* Builder workspace */
.builder-workspace {
    margin-top: 1rem;
}

.workspace-grid {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 2rem;
    align-items: start;
}

@media (max-width: 800px) {
    .workspace-grid {
        grid-template-columns: 1fr;
    }
}

.controls-panel {
    background: #FFFFFF;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
    border: 1px solid #E2E8F0;
}

.preview-panel {
    background: #FFFFFF;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
    border: 1px solid #E2E8F0;
    min-height: 400px;
}

.form-group {
    margin-bottom: 1.25rem;
}

.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.4rem;
    color: #1B3A5C;
    font-size: 0.95rem;
}

.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.65rem 0.75rem;
    border: 1.5px solid #CBD5E0;
    border-radius: 8px;
    font-size: 0.95rem;
    font-family: inherit;
    color: #1B2A3A;
    background-color: #FAFBFC;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #FFB347;
    box-shadow: 0 0 0 3px rgba(255, 179, 71, 0.2);
}

.form-group textarea {
    resize: vertical;
    min-height: 80px;
}

.form-actions {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.btn-primary {
    background-color: #1B3A5C;
    color: #FFFFFF;
    border: none;
    padding: 0.7rem 1.5rem;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s, transform 0.1s;
}

.btn-primary:hover {
    background-color: #2A4F7A;
}

.btn-primary:active {
    transform: scale(0.97);
}

.btn-secondary {
    background-color: #EDF2F7;
    color: #1B3A5C;
    border: 1.5px solid #CBD5E0;
    padding: 0.7rem 1.5rem;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s;
}

.btn-secondary:hover {
    background-color: #E2E8F0;
}

.save-indicator {
    margin-top: 0.75rem;
    font-size: 0.85rem;
    color: #718096;
    min-height: 1.2em;
}

/* Preview header */
.preview-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid #E2E8F0;
}

.preview-header h3 {
    font-size: 1.15rem;
    font-weight: 700;
    color: #1B3A5C;
}

.preview-actions {
    display: flex;
    gap: 0.5rem;
}

.btn-icon {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    background: none;
    border: 1.5px solid #CBD5E0;
    padding: 0.45rem 0.75rem;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 600;
    color: #1B3A5C;
    cursor: pointer;
    transition: background-color 0.2s, border-color 0.2s;
}

.btn-icon:hover {
    background-color: #EDF2F7;
    border-color: #A0AEC0;
}

/* Checklist output */
.checklist-output {
    font-size: 0.95rem;
    line-height: 1.7;
}

.checklist-output .empty-state {
    color: #718096;
    font-style: italic;
    padding: 2rem 0;
    text-align: center;
}

.checklist-section {
    margin-bottom: 1.25rem;
}

.checklist-section h4 {
    font-size: 1rem;
    font-weight: 700;
    color: #1B3A5C;
    margin-bottom: 0.5rem;
    padding: 0.3rem 0.5rem;
    background-color: #EBF4FF;
    border-left: 4px solid #FFB347;
    border-radius: 0 4px 4px 0;
}

.checklist-item {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    padding: 0.35rem 0;
    border-bottom: 1px dotted #E2E8F0;
}

.checklist-item .check-box {
    flex-shrink: 0;
    width: 18px;
    height: 18px;
    border: 2px solid #1B3A5C;
    border-radius: 3px;
    margin-top: 2px;
}

.checklist-item .item-text {
    flex: 1;
}

.checklist-item .weather-note {
    font-size: 0.8rem;
    color: #C05621;
    font-weight: 600;
    margin-left: 0.25rem;
}

/* Supporting content */
.supporting-content {
    margin-top: 3rem;
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
}

@media (min-width: 900px) {
    .supporting-content {
        grid-template-columns: 1fr 1fr;
    }
    .reference-notes {
        grid-column: 1 / -1;
    }
}

.scenario-walkthrough,
.mistakes-table-wrapper,
.reference-notes {
    background: #FFFFFF;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    border: 1px solid #E2E8F0;
}

.scenario-walkthrough h3,
.mistakes-table-wrapper h3,
.reference-notes h3 {
    font-size: 1.15rem;
    font-weight: 700;
    color: #1B3A5C;
    margin-bottom: 0.75rem;
}

.scenario-walkthrough p {
    color: #2D3748;
    line-height: 1.7;
}

.mistakes-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.mistakes-table th {
    background-color: #1B3A5C;
    color: #FFFFFF;
    padding: 0.6rem 0.75rem;
    text-align: left;
    font-weight: 600;
}

.mistakes-table td {
    padding: 0.6rem 0.75rem;
    border-bottom: 1px solid #E2E8F0;
    vertical-align: top;
}

.mistakes-table tr:nth-child(even) td {
    background-color: #F7FAFC;
}

.reference-notes ul {
    list-style: none;
    padding: 0;
}

.reference-notes li {
    padding: 0.5rem 0;
    border-bottom: 1px solid #EDF2F7;
    color: #2D3748;
    line-height: 1.6;
}

.reference-notes li:last-child {
    border-bottom: none;
}

/* Footer */
.site-footer {
    background-color: #1B3A5C;
    color: #D0DFF0;
    padding: 1.5rem;
    margin-top: auto;
}

.footer-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.footer-inner p {
    font-size: 0.85rem;
    max-width: 600px;
}

.footer-inner a {
    color: #FFB347;
    text-decoration: underline;
}

.footer-nav {
    display: flex;
    gap: 1.25rem;
    flex-wrap: wrap;
}

.footer-nav a {
    color: #D0DFF0;
    text-decoration: none;
    font-size: 0.85rem;
}

.footer-nav a:hover {
    color: #FFB347;
    text-decoration: underline;
}

/* Print styles */
@media print {
    .site-header,
    .site-footer,
    .controls-panel,
    .supporting-content,
    .preview-actions,
    .hero {
        display: none !important;
    }
    .workspace-grid {
        display: block;
    }
    .preview-panel {
        box-shadow: none;
        border: none;
        padding: 0;
    }
    .checklist-item .check-box {
        border: 2px solid #000;
    }
    body {
        background: #fff;
        color: #000;
    }
}

/* Focus visible */
:focus-visible {
    outline: 3px solid #FFB347;
    outline-offset: 2px;
}

/* Utility */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0,0,0,0);
    border: 0;
}



/* Factory-injected deployment helpers. The AI owns the site design above this block. */
.ad-unit {
  width: min(100%, 720px);
  min-height: 120px;
  margin: 24px auto;
  display: block;
}

.legal-page {
  width: min(900px, calc(100% - 32px));
  margin: 40px auto;
}

.factory-fallback-nav {
  width: min(900px, calc(100% - 32px));
  margin: 24px auto 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  align-items: center;
  font-size: 0.95rem;
}

.factory-fallback-nav a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid currentColor;
}
