/* Property Downturn Preparation Checklist - Styles */
:root {
    --color-primary: #2C3E50;
    --color-secondary: #5D737E;
    --color-accent: #E67E22;
    --color-success: #27AE60;
    --color-warning: #F39C12;
    --color-danger: #E74C3C;
    --color-bg: #F8F9FA;
    --color-card: #FFFFFF;
    --color-text: #2C3E50;
    --color-text-light: #7F8C8D;
    --color-border: #E0E0E0;
    
    --font-main: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.1);
    --shadow-md: 0 4px 6px rgba(0,0,0,0.1);
    --shadow-lg: 0 10px 25px rgba(0,0,0,0.1);
    --radius: 8px;
    --radius-lg: 12px;
}

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

body {
    font-family: var(--font-main);
    color: var(--color-text);
    background: var(--color-bg);
    line-height: 1.6;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
.site-header {
    background: var(--color-card);
    border-bottom: 1px solid var(--color-border);
    padding: 15px 0;
    position: sticky;
    top: 0;
    z-index: 100;
}

.site-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    font-size: 1.25rem;
    color: var(--color-primary);
}

.main-nav {
    display: flex;
    gap: 25px;
}

.main-nav a {
    color: var(--color-text);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
}

.main-nav a:hover {
    color: var(--color-accent);
}

/* Hero */
.hero {
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
    color: white;
    padding: 60px 0;
    text-align: center;
}

.hero h1 {
    font-size: 2.5rem;
    margin-bottom: 15px;
    font-weight: 700;
}

.hero-subtitle {
    font-size: 1.15rem;
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto 30px;
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 40px;
}

.stat {
    text-align: center;
}

.stat-number {
    display: block;
    font-size: 2rem;
    font-weight: 700;
}

.stat-label {
    font-size: 0.9rem;
    opacity: 0.8;
}

/* Sections */
section {
    padding: 50px 0;
}

section h2 {
    font-size: 1.75rem;
    margin-bottom: 15px;
    color: var(--color-primary);
}

.section-intro {
    color: var(--color-text-light);
    margin-bottom: 30px;
    max-width: 700px;
}

/* Checklist Section */
.checklist-section {
    background: var(--color-card);
}

.setup-panel {
    display: grid;
    gap: 20px;
    margin-bottom: 30px;
}

.setup-card {
    background: var(--color-bg);
    padding: 25px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--color-border);
}

.setup-card h3 {
    margin-bottom: 15px;
    font-size: 1.1rem;
}

.radio-group {
    display: grid;
    gap: 10px;
}

.radio-option {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    padding: 10px;
    border-radius: var(--radius);
    transition: background 0.2s;
}

.radio-option:hover {
    background: rgba(0,0,0,0.03);
}

.radio-option input {
    display: none;
}

.radio-custom {
    width: 20px;
    height: 20px;
    border: 2px solid var(--color-border);
    border-radius: 50%;
    position: relative;
    flex-shrink: 0;
}

.radio-option input:checked + .radio-custom {
    border-color: var(--color-accent);
}

.radio-option input:checked + .radio-custom::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 10px;
    height: 10px;
    background: var(--color-accent);
    border-radius: 50%;
}

.btn-primary {
    background: var(--color-accent);
    color: white;
    border: none;
    padding: 15px 30px;
    font-size: 1rem;
    font-weight: 600;
    border-radius: var(--radius);
    cursor: pointer;
    transition: background 0.2s, transform 0.1s;
}

.btn-primary:hover {
    background: #D35400;
}

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

.btn-secondary {
    background: var(--color-bg);
    color: var(--color-text);
    border: 1px solid var(--color-border);
    padding: 10px 20px;
    font-size: 0.9rem;
    border-radius: var(--radius);
    cursor: pointer;
    transition: background 0.2s;
}

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

/* Checklist Output */
.checklist-output {
    margin-top: 30px;
}

.checklist-output.hidden {
    display: none;
}

.checklist-header {
    margin-bottom: 25px;
}

.progress-bar {
    height: 8px;
    background: var(--color-border);
    border-radius: 4px;
    overflow: hidden;
    margin: 10px 0;
}

.progress-fill {
    height: 100%;
    background: var(--color-success);
    width: 0%;
    transition: width 0.3s ease;
}

.progress-text {
    color: var(--color-text-light);
    font-size: 0.9rem;
}

.checklist-categories {
    display: grid;
    gap: 20px;
}

.category {
    background: var(--color-bg);
    border-radius: var(--radius-lg);
    padding: 20px;
    border: 1px solid var(--color-border);
}

.category-title {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
    font-size: 1.1rem;
}

.category-title.urgent {
    color: var(--color-danger);
}

.category-title.important {
    color: var(--color-accent);
}

.category-title.planned {
    color: var(--color-success);
}

.category-icon {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-weight: 700;
    font-size: 0.9rem;
}

.urgent .category-icon {
    background: var(--color-danger);
    color: white;
}

.important .category-icon {
    background: var(--color-accent);
    color: white;
}

.planned .category-icon {
    background: var(--color-success);
    color: white;
}

.checklist-items {
    list-style: none;
}

.checklist-items li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid var(--color-border);
}

.checklist-items li:last-child {
    border-bottom: none;
}

.checklist-items input[type="checkbox"] {
    width: 20px;
    height: 20px;
    margin-top: 2px;
    cursor: pointer;
    accent-color: var(--color-success);
}

.checklist-items label {
    cursor: pointer;
    flex: 1;
    line-height: 1.5;
}

.checklist-items li.checked label {
    text-decoration: line-through;
    color: var(--color-text-light);
}

.checklist-actions {
    display: flex;
    gap: 10px;
    margin-top: 25px;
    flex-wrap: wrap;
}

/* Guide Section */
.guide-section {
    background: var(--color-bg);
}

.guide-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.guide-card {
    background: var(--color-card);
    padding: 25px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
}

.guide-card h3 {
    margin-bottom: 10px;
    color: var(--color-primary);
}

.guide-card p {
    color: var(--color-text-light);
    font-size: 0.95rem;
}

.maintenance-matrix {
    background: var(--color-card);
    padding: 30px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
}

.maintenance-matrix h3 {
    margin-bottom: 10px;
}

.maintenance-matrix > p {
    color: var(--color-text-light);
    margin-bottom: 20px;
}

.matrix-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.matrix-item {
    padding: 20px;
    border-radius: var(--radius);
    border: 2px solid;
}

.matrix-item.high-priority {
    border-color: var(--color-danger);
    background: rgba(231, 76, 60, 0.05);
}

.matrix-item.medium-priority {
    border-color: var(--color-accent);
    background: rgba(230, 126, 34, 0.05);
}

.matrix-item.low-priority {
    border-color: var(--color-success);
    background: rgba(39, 174, 96, 0.05);
}

.matrix-item h4 {
    margin-bottom: 10px;
}

.matrix-item ul {
    list-style: none;
    font-size: 0.9rem;
}

.matrix-item li {
    padding: 5px 0;
    padding-left: 15px;
    position: relative;
}

.matrix-item li::before {
    content: '•';
    position: absolute;
    left: 0;
}

/* Scenarios Section */
.scenarios-section {
    background: var(--color-card);
}

.scenario-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 25px;
    flex-wrap: wrap;
}

.scenario-tab {
    padding: 12px 20px;
    border: 1px solid var(--color-border);
    background: var(--color-bg);
    border-radius: var(--radius);
    cursor: pointer;
    font-weight: 500;
    transition: all 0.2s;
}

.scenario-tab:hover {
    border-color: var(--color-secondary);
}

.scenario-tab.active {
    background: var(--color-primary);
    color: white;
    border-color: var(--color-primary);
}

.scenario-panel {
    display: none;
    background: var(--color-bg);
    padding: 25px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--color-border);
}

.scenario-panel.active {
    display: block;
}

.scenario-panel h3 {
    margin-bottom: 10px;
}

.scenario-panel > p {
    color: var(--color-text-light);
    margin-bottom: 20px;
}

.scenario-actions {
    background: var(--color-card);
    padding: 20px;
    border-radius: var(--radius);
    margin-bottom: 15px;
}

.scenario-actions h4 {
    margin-bottom: 10px;
}

.scenario-actions ul {
    list-style: none;
}

.scenario-actions li {
    padding: 5px 0;
    padding-left: 20px;
    position: relative;
}

.scenario-actions li::before {
    content: '→';
    position: absolute;
    left: 0;
    color: var(--color-accent);
}

.scenario-note {
    font-style: italic;
    color: var(--color-text-light);
    font-size: 0.9rem;
}

/* FAQ Section */
.faq-section {
    background: var(--color-bg);
}

.faq-list {
    display: grid;
    gap: 15px;
}

.faq-item {
    background: var(--color-card);
    border-radius: var(--radius);
    border: 1px solid var(--color-border);
    overflow: hidden;
}

.faq-item summary {
    padding: 20px;
    cursor: pointer;
    font-weight: 600;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.faq-item summary::-webkit-details-marker {
    display: none;
}

.faq-item summary::after {
    content: '+';
    font-size: 1.5rem;
    color: var(--color-accent);
}

.faq-item[open] summary::after {
    content: '−';
}

.faq-item p {
    padding: 0 20px 20px;
    color: var(--color-text-light);
}

/* Assumptions Section */
.assumptions-section {
    background: var(--color-card);
}

.assumptions-box {
    background: var(--color-bg);
    padding: 30px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--color-border);
}

.assumptions-box h3 {
    margin-bottom: 15px;
    color: var(--color-primary);
}

.assumptions-box ul {
    margin-bottom: 25px;
    padding-left: 20px;
}

.assumptions-box li {
    margin-bottom: 8px;
}

.last-updated {
    color: var(--color-text-light);
    font-size: 0.85rem;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--color-border);
}

/* Footer */
.site-footer {
    background: var(--color-primary);
    color: white;
    padding: 40px 0;
}

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

.footer-brand {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 20px;
    font-weight: 600;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 25px;
    margin-bottom: 15px;
    flex-wrap: wrap;
}

.footer-links a {
    color: rgba(255,255,255,0.8);
    text-decoration: none;
    transition: color 0.2s;
}

.footer-links a:hover {
    color: white;
}

.footer-note {
    font-size: 0.9rem;
    opacity: 0.7;
}

.footer-note a {
    color: rgba(255,255,255,0.9);
}

/* Responsive */
@media (max-width: 768px) {
    .hero h1 {
        font-size: 1.75rem;
    }
    
    .hero-stats {
        gap: 20px;
    }
    
    .stat-number {
        font-size: 1.5rem;
    }
    
    .main-nav {
        display: none;
    }
    
    .setup-card {
        padding: 20px;
    }
    
    .checklist-actions {
        flex-direction: column;
    }
    
    .btn-secondary {
        width: 100%;
    }
    
    .scenario-tabs {
        flex-direction: column;
    }
    
    .scenario-tab {
        width: 100%;
        text-align: center;
    }
}

@media print {
    .site-header,
    .setup-panel,
    .checklist-actions,
    .site-footer,
    .scenario-tabs {
        display: none;
    }
    
    .checklist-output {
        display: block !important;
    }
    
    body {
        background: white;
    }
    
    .category {
        break-inside: avoid;
    }
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
    }
}

:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 2px;
}

/* Animation for checklist items */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.checklist-items li {
    animation: fadeIn 0.3s ease forwards;
}

.checklist-items li:nth-child(1) { animation-delay: 0.05s; }
.checklist-items li:nth-child(2) { animation-delay: 0.1s; }
.checklist-items li:nth-child(3) { animation-delay: 0.15s; }
.checklist-items li:nth-child(4) { animation-delay: 0.2s; }
.checklist-items li:nth-child(5) { animation-delay: 0.25s; }


/* 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;
}
