/* Traffic Stop Rights & Fines Checker - CSS */

/* CSS Variables - Design System */
:root {
    --bg-primary: #0F172A;
    --surface-dark: #111827;
    --card-bg: #1F2937;
    --text-primary: #FFFFFF;
    --accent-blue: #38BDF8;
    --success-green: #22C55E;
    --warning-yellow: #F59E0B;
    --danger-red: #EF4444;
    --muted: #9CA3AF;
    --border-color: #374151;
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --transition: all 0.2s ease-in-out;
}

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    font-size: 16px;
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* Header */
.header {
    background-color: var(--surface-dark);
    padding: 1rem 0;
    border-bottom: 1px solid var(--border-color);
}

.logo h1 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

.logo .subtitle {
    color: var(--muted);
    font-size: 0.9rem;
    font-weight: 500;
}

/* Hero Section */
.hero {
    padding: 3rem 0;
    text-align: center;
    background: linear-gradient(135deg, var(--bg-primary) 0%, var(--surface-dark) 100%);
}

.hero-title {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--text-primary);
    line-height: 1.2;
}

.hero-subtitle {
    font-size: 1.1rem;
    color: var(--accent-blue);
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.hero-support {
    font-size: 1rem;
    color: var(--muted);
    margin-bottom: 2rem;
}

.cta-container {
    margin-top: 2rem;
}

.cta-button {
    background: linear-gradient(135deg, var(--accent-blue) 0%, #0EA5E9 100%);
    color: white;
    border: none;
    padding: 1rem 2rem;
    font-size: 1.1rem;
    font-weight: 600;
    border-radius: 0.75rem;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: var(--shadow);
    min-width: 280px;
}

.cta-button:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.cta-button:active {
    transform: translateY(0);
}

/* Main Content */
.main-content {
    padding: 2rem 0;
    min-height: 60vh;
}

/* Step Sections */
.step-section {
    margin-bottom: 3rem;
}

.step-section h3 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
    text-align: center;
}

/* Vehicle Grid */
.vehicle-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 1rem;
    max-width: 600px;
    margin: 0 auto;
}

.vehicle-card {
    background-color: var(--card-bg);
    border: 2px solid var(--border-color);
    border-radius: 0.75rem;
    padding: 1.5rem 1rem;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.vehicle-card:hover {
    border-color: var(--accent-blue);
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.vehicle-card.selected {
    border-color: var(--accent-blue);
    background-color: rgba(56, 189, 248, 0.1);
}

.vehicle-icon {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.vehicle-name {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-primary);
}

/* Offense Grid */
.offense-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 1rem;
    max-width: 800px;
    margin: 0 auto;
}

.offense-card {
    background-color: var(--card-bg);
    border: 2px solid var(--border-color);
    border-radius: 0.75rem;
    padding: 1.5rem 1rem;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.offense-card:hover {
    border-color: var(--warning-yellow);
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.offense-card.selected {
    border-color: var(--warning-yellow);
    background-color: rgba(245, 158, 11, 0.1);
}

.offense-icon {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.offense-name {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.2;
}

/* State Select */
.state-select {
    background-color: var(--card-bg);
    border: 2px solid var(--border-color);
    border-radius: 0.5rem;
    padding: 1rem;
    font-size: 1rem;
    color: var(--text-primary);
    width: 100%;
    max-width: 400px;
    margin: 0 auto;
    display: block;
    cursor: pointer;
}

.state-select:focus {
    outline: none;
    border-color: var(--accent-blue);
    box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.1);
}

/* Results Section */
.results-section {
    margin-top: 2rem;
}

.results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.result-card {
    background-color: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 0.75rem;
    padding: 1.5rem;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.result-card:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-lg);
}

.result-card h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

/* Fine Amount Card */
.fine-amount {
    border-left: 4px solid var(--success-green);
}

.fine-display {
    text-align: center;
    margin-bottom: 1rem;
}

.fine-amount-value {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--success-green);
    display: block;
}

.fine-description {
    font-size: 0.9rem;
    color: var(--muted);
    margin-top: 0.5rem;
}

.fine-details {
    margin: 1rem 0;
}

.fine-details p {
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.copy-button {
    background-color: var(--accent-blue);
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 0.5rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    width: 100%;
}

.copy-button:hover {
    background-color: #0EA5E9;
}

/* Seizure Info Card */
.seizure-info {
    border-left: 4px solid var(--warning-yellow);
}

.seizure-indicators {
    margin-bottom: 1rem;
}

.seizure-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
    padding: 0.75rem;
    background-color: rgba(55, 65, 81, 0.3);
    border-radius: 0.5rem;
}

.seizure-icon {
    font-size: 1.25rem;
    min-width: 24px;
}

.seizure-label {
    font-weight: 600;
    color: var(--text-primary);
    min-width: 120px;
}

.seizure-status {
    color: var(--muted);
}

.seizure-explanation {
    font-size: 0.9rem;
    color: var(--muted);
    line-height: 1.5;
}

/* Documents Card */
.documents-required {
    border-left: 4px solid var(--accent-blue);
}

.documents-list {
    margin-bottom: 1rem;
}

.document-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--border-color);
}

.document-item:last-child {
    border-bottom: none;
}

.document-item::before {
    content: "📄";
    font-size: 1rem;
}

.digilocker-note {
    background-color: rgba(56, 189, 248, 0.1);
    border: 1px solid var(--accent-blue);
    border-radius: 0.5rem;
    padding: 1rem;
}

.digilocker-note p {
    font-size: 0.9rem;
    color: var(--accent-blue);
    margin-bottom: 0.5rem;
}

.digilocker-note p:last-child {
    margin-bottom: 0;
}

/* Safe Scripts Card */
.safe-scripts {
    border-left: 4px solid var(--success-green);
}

.scripts-list {
    margin-bottom: 1rem;
}

.script-item {
    background-color: rgba(34, 197, 94, 0.1);
    border: 1px solid var(--success-green);
    border-radius: 0.5rem;
    padding: 1rem;
    margin-bottom: 0.75rem;
    position: relative;
}

.script-item::before {
    content: "💬";
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    font-size: 1rem;
}

.script-item:last-child {
    margin-bottom: 0;
}

.tone-note {
    font-size: 0.9rem;
    color: var(--muted);
    text-align: center;
    padding: 0.75rem;
    background-color: rgba(55, 65, 81, 0.3);
    border-radius: 0.5rem;
}

/* Dispute Info Card */
.dispute-info {
    border-left: 4px solid var(--warning-yellow);
}

.payment-options h4 {
    color: var(--success-green);
    margin-bottom: 0.5rem;
    font-size: 1rem;
}

.payment-options ul {
    list-style: none;
    margin-bottom: 1rem;
}

.payment-options li {
    padding: 0.25rem 0;
    position: relative;
    padding-left: 1.5rem;
}

.payment-options li::before {
    content: "💳";
    position: absolute;
    left: 0;
    top: 0.25rem;
}

.dispute-guidance {
    margin-top: 1rem;
}

/* Common Mistakes Card */
.common-mistakes {
    border-left: 4px solid var(--danger-red);
}

.mistakes-list {
    margin-bottom: 1rem;
}

.mistake-item {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    padding: 0.75rem;
    background-color: rgba(239, 68, 68, 0.1);
    border: 1px solid var(--danger-red);
    border-radius: 0.5rem;
    margin-bottom: 0.5rem;
}

.mistake-item:last-child {
    margin-bottom: 0;
}

.mistake-item::before {
    content: "❌";
    font-size: 1rem;
    margin-top: 0.125rem;
}

.mistake-text {
    font-size: 0.9rem;
    color: var(--text-primary);
    line-height: 1.4;
}

/* Legal Disclaimer */
.legal-disclaimer {
    background-color: rgba(239, 68, 68, 0.1);
    border: 2px solid var(--danger-red);
    border-radius: 0.75rem;
    padding: 1.5rem;
    margin: 2rem 0;
}

.legal-disclaimer h4 {
    color: var(--danger-red);
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

.legal-disclaimer p {
    color: var(--text-primary);
    line-height: 1.6;
    margin-bottom: 0.75rem;
}

.legal-disclaimer p:last-child {
    margin-bottom: 0;
}

/* Action Buttons */
.action-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.action-button {
    background-color: var(--card-bg);
    color: var(--text-primary);
    border: 2px solid var(--border-color);
    padding: 0.75rem 1.5rem;
    border-radius: 0.5rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.action-button:hover {
    border-color: var(--accent-blue);
    background-color: rgba(56, 189, 248, 0.1);
}

/* FAQ Section */
.faq-section {
    background-color: var(--surface-dark);
    padding: 3rem 0;
    margin-top: 3rem;
}

.faq-section h2 {
    text-align: center;
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 2rem;
    color: var(--text-primary);
}

.faq-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
}

.faq-item {
    background-color: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 0.75rem;
    padding: 1.5rem;
    box-shadow: var(--shadow);
}

.faq-item h4 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    color: var(--accent-blue);
}

.faq-item p {
    color: var(--text-primary);
    line-height: 1.6;
    font-size: 0.95rem;
}

/* Footer */
.footer {
    background-color: var(--surface-dark);
    border-top: 1px solid var(--border-color);
    padding: 2rem 0;
    text-align: center;
}

.footer p {
    color: var(--muted);
    margin-bottom: 0.5rem;
}

.footer-disclaimer {
    font-size: 0.9rem;
    color: var(--warning-yellow) !important;
}

/* Responsive Design - Mobile First */

/* Small devices (landscape phones, 576px and up) */
@media (min-width: 576px) {
    .container {
        padding: 0 2rem;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .vehicle-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .offense-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Medium devices (tablets, 768px and up) */
@media (min-width: 768px) {
    .hero {
        padding: 4rem 0;
    }
    
    .hero-title {
        font-size: 3rem;
    }
    
    .hero-subtitle {
        font-size: 1.25rem;
    }
    
    .vehicle-grid {
        grid-template-columns: repeat(4, 1fr);
    }
    
    .offense-grid {
        grid-template-columns: repeat(4, 1fr);
    }
    
    .results-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Large devices (desktops, 992px and up) */
@media (min-width: 992px) {
    .hero-title {
        font-size: 3.5rem;
    }
    
    .results-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .faq-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Extra large devices (large desktops, 1200px and up) */
@media (min-width: 1200px) {
    .results-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Animation Classes */
.fade-in {
    animation: fadeIn 0.3s ease-in-out;
}

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

.slide-in {
    animation: slideIn 0.4s ease-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Loading States */
.loading {
    opacity: 0.6;
    pointer-events: none;
}

.spinner {
    border: 3px solid var(--border-color);
    border-top: 3px solid var(--accent-blue);
    border-radius: 50%;
    width: 24px;
    height: 24px;
    animation: spin 1s linear infinite;
    display: inline-block;
    margin-right: 0.5rem;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Focus States for Accessibility */
button:focus,
select:focus {
    outline: 2px solid var(--accent-blue);
    outline-offset: 2px;
}

/* Print Styles */
@media print {
    .header,
    .hero,
    .faq-section,
    .footer {
        display: none;
    }
    
    .main-content {
        padding: 0;
    }
    
    .result-card {
        break-inside: avoid;
        margin-bottom: 1rem;
    }
}
