/* ==========================================================================
   Website Project Questionnaire Styles
   Doc Bear Enterprises, LLC
   Matches the styling of docbear-ent.com
   ========================================================================== */

/* CSS Reset & Base */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    /* Brand Colors - matching docbear-ent.com */
    --primary-color: #2c5530;      /* Forest green */
    --primary-dark: #1e3a21;
    --primary-light: #3d7342;
    --accent-color: #d4a84b;       /* Gold accent */
    --accent-hover: #c49a3d;
    
    /* Neutrals */
    --text-dark: #333333;
    --text-medium: #555555;
    --text-light: #777777;
    --bg-light: #f8f9fa;
    --bg-white: #ffffff;
    --border-color: #e0e0e0;
    --border-focus: #2c5530;
    
    /* Status Colors */
    --error-color: #d32f2f;
    --success-color: #388e3c;
    
    /* Spacing */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 1.5rem;
    --spacing-lg: 2rem;
    --spacing-xl: 3rem;
    
    /* Typography */
    --font-primary: 'Open Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-heading: 'Montserrat', 'Open Sans', sans-serif;
    
    /* Borders & Shadows */
    --border-radius: 8px;
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.12);
}

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

body {
    font-family: var(--font-primary);
    color: var(--text-dark);
    background-color: var(--bg-white);
    line-height: 1.6;
    padding-top: 80px; /* Account for fixed header */
}

/* ==========================================================================
   Header / Navigation
   ========================================================================== */

header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.98);
    box-shadow: var(--shadow-sm);
    z-index: 1000;
    transition: background 0.3s ease;
}

header .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-md);
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--spacing-sm) 0;
}

.logo {
    display: flex;
    align-items: center;
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary-color);
    text-decoration: none;
}

.logo img {
    height: 50px;
    margin-right: 10px;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: var(--spacing-md);
}

.nav-links a {
    color: var(--text-dark);
    text-decoration: none;
    font-weight: 600;
    padding: var(--spacing-xs) var(--spacing-sm);
    border-radius: var(--border-radius);
    transition: color 0.2s, background 0.2s;
}

.nav-links a:hover {
    color: var(--primary-color);
    background: var(--bg-light);
}

/* Mobile Navigation */
@media (max-width: 768px) {
    .nav-links {
        display: none;
    }
    
    .logo {
        font-size: 1rem;
    }
    
    .logo img {
        height: 40px;
    }
}

/* ==========================================================================
   Hero Section
   ========================================================================== */

.hero {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
    text-align: center;
    padding: var(--spacing-xl) var(--spacing-md);
}

.hero h1 {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    margin-bottom: var(--spacing-sm);
}

.hero .subtitle {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: var(--spacing-sm);
    color: var(--accent-color);
}

.hero .tagline {
    font-size: 1.1rem;
    max-width: 700px;
    margin: 0 auto;
    opacity: 0.95;
}

@media (max-width: 768px) {
    .hero {
        padding: var(--spacing-lg) var(--spacing-sm);
    }
    
    .hero h1 {
        font-size: 1.75rem;
    }
    
    .hero .subtitle {
        font-size: 1.2rem;
    }
    
    .hero .tagline {
        font-size: 1rem;
    }
}

/* ==========================================================================
   Form Section
   ========================================================================== */

.form-section {
    padding: var(--spacing-xl) var(--spacing-md);
    background: var(--bg-light);
}

.form-section .container {
    max-width: 800px;
    margin: 0 auto;
}

.form-intro {
    background: var(--bg-white);
    padding: var(--spacing-md);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
    margin-bottom: var(--spacing-lg);
    border-left: 4px solid var(--primary-color);
}

.form-intro p {
    margin-bottom: var(--spacing-xs);
}

.form-intro p:last-child {
    margin-bottom: 0;
}

/* Form Parts */
.form-part {
    background: var(--bg-white);
    padding: var(--spacing-lg);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-md);
    margin-bottom: var(--spacing-lg);
}

.form-part h2 {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-bottom: var(--spacing-md);
    padding-bottom: var(--spacing-sm);
    border-bottom: 2px solid var(--border-color);
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.part-number {
    background: var(--primary-color);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: var(--border-radius);
    font-size: 0.875rem;
    font-weight: 600;
}

/* Form Groups */
.form-group {
    margin-bottom: var(--spacing-md);
}

.form-group:last-child {
    margin-bottom: 0;
}

.form-group > label {
    display: block;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: var(--spacing-xs);
}

.required {
    color: var(--error-color);
}

/* Text Inputs & Textareas */
input[type="text"],
input[type="email"],
input[type="tel"],
input[type="date"],
textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    font-family: var(--font-primary);
    font-size: 1rem;
    color: var(--text-dark);
    background: var(--bg-white);
    border: 2px solid var(--border-color);
    border-radius: var(--border-radius);
    transition: border-color 0.2s, box-shadow 0.2s;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="tel"]:focus,
input[type="date"]:focus,
textarea:focus {
    outline: none;
    border-color: var(--border-focus);
    box-shadow: 0 0 0 3px rgba(44, 85, 48, 0.15);
}

textarea {
    min-height: 100px;
    resize: vertical;
}

input::placeholder,
textarea::placeholder {
    color: var(--text-light);
}

/* Checkboxes & Radio Buttons */
.checkbox-group,
.radio-group {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-xs);
}

.checkbox-label,
.radio-label {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    background: var(--bg-light);
    border: 2px solid transparent;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s;
    font-weight: normal;
}

.checkbox-label:hover,
.radio-label:hover {
    background: #e8f5e9;
    border-color: var(--primary-light);
}

.checkbox-label input,
.radio-label input {
    margin-top: 0.2rem;
    width: 18px;
    height: 18px;
    accent-color: var(--primary-color);
    flex-shrink: 0;
}

/* Form Notes */
.form-note {
    font-size: 0.875rem;
    color: var(--text-light);
    margin-top: var(--spacing-xs);
    padding: var(--spacing-sm);
    background: #fff8e1;
    border-radius: var(--border-radius);
    border-left: 3px solid var(--accent-color);
}

/* Honeypot (spam protection) */
.honeypot {
    position: absolute;
    left: -9999px;
    opacity: 0;
    height: 0;
    overflow: hidden;
}

/* ==========================================================================
   Submit Section
   ========================================================================== */

.form-submit {
    background: var(--bg-white);
    padding: var(--spacing-lg);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-md);
    text-align: center;
    border-top: 4px solid var(--primary-color);
}

.form-submit h2 {
    font-family: var(--font-heading);
    color: var(--primary-color);
    margin-bottom: var(--spacing-md);
}

.next-steps {
    text-align: left;
    max-width: 500px;
    margin: 0 auto var(--spacing-md);
    padding-left: var(--spacing-md);
}

.next-steps li {
    margin-bottom: var(--spacing-xs);
    color: var(--text-medium);
}

.consent-group {
    max-width: 500px;
    margin: var(--spacing-md) auto;
    text-align: left;
}

.consent-group .checkbox-label {
    background: #e8f5e9;
    border: 2px solid var(--primary-light);
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 1rem 2rem;
    font-family: var(--font-primary);
    font-size: 1.1rem;
    font-weight: 600;
    text-decoration: none;
    border: none;
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s, background 0.2s;
}

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

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-primary:disabled {
    background: var(--text-light);
    cursor: not-allowed;
    transform: none;
}

.btn-secondary {
    background: var(--accent-color);
    color: var(--text-dark);
}

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

/* ==========================================================================
   Footer
   ========================================================================== */

footer {
    background: var(--text-dark);
    color: white;
    padding: var(--spacing-xl) var(--spacing-md) var(--spacing-lg);
}

footer .container {
    max-width: 1200px;
    margin: 0 auto;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--spacing-lg);
    margin-bottom: var(--spacing-lg);
}

.footer-section h4 {
    font-family: var(--font-heading);
    color: var(--accent-color);
    margin-bottom: var(--spacing-sm);
}

.footer-section p {
    margin-bottom: var(--spacing-xs);
    color: rgba(255, 255, 255, 0.85);
}

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

.footer-section a:hover {
    color: var(--accent-color);
}

.footer-bottom {
    text-align: center;
    padding-top: var(--spacing-md);
    border-top: 1px solid rgba(255, 255, 255, 0.2);
}

.footer-bottom p {
    margin-bottom: var(--spacing-xs);
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
}

/* ==========================================================================
   Responsive Adjustments
   ========================================================================== */

@media (max-width: 768px) {
    body {
        padding-top: 70px;
    }
    
    .form-section {
        padding: var(--spacing-md) var(--spacing-sm);
    }
    
    .form-part {
        padding: var(--spacing-md);
    }
    
    .form-part h2 {
        font-size: 1.25rem;
        flex-direction: column;
        align-items: flex-start;
    }
    
    .btn {
        width: 100%;
        text-align: center;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
}

/* ==========================================================================
   Accessibility
   ========================================================================== */

/* Focus states for keyboard navigation */
a:focus,
button:focus,
input:focus,
textarea:focus,
select:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* Reduced motion preference */
@media (prefers-reduced-motion: reduce) {
    * {
        animation: none !important;
        transition: none !important;
    }
    
    html {
        scroll-behavior: auto;
    }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    :root {
        --border-color: #000000;
        --text-light: #333333;
    }
    
    .checkbox-label,
    .radio-label {
        border: 2px solid var(--text-dark);
    }
}
