/* Appointment Page Styles */

:root {
    --primary: #308ce8;
    --background-light: #f6f7f8;
    --background-dark: #111921;
    --success: #10b981;
}

/* Ensure Clash Grotesk is used on the appointment page */
html, body {
    font-family: 'Clash Grotesk', system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial;
}

/* Typography tokens and accessible color tokens (match main site) */
:root {
    --base-font-size: 16px;
    --font-sans: 'Clash Grotesk', system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial;
    --text-color: #0e141b;
    --muted-color: #374151;
    --subtle-color: #6b7280;
}

html { font-size: var(--base-font-size); }

body {
    font-family: var(--font-sans);
    color: var(--text-color);
}

/* Heading scale */
h1 { font-size: 2.25rem; line-height: 1.08; }
h2 { font-size: 1.5rem; line-height: 1.15; }
h3 { font-size: 1.125rem; line-height: 1.2; }

/* Contrast overrides for some Tailwind utility classes */
.text-gray-600 { color: var(--muted-color) !important; }
.text-gray-500 { color: var(--subtle-color) !important; }
.text-gray-400 { color: #9ca3af !important; }

.dark {
    --text-color: #e5e7eb;
    --muted-color: #9ca3af;
    --subtle-color: #6b7280;
}

.dark body { color: var(--text-color); }

p, li, label, input, select, textarea, button { font-size: 1rem; }

/* Navbar contrast tokens for appointment page */
:root {
    --nav-text: #0e141b;
    --nav-text-hover: var(--primary);
}
.dark {
    --nav-text: #e5e7eb;
}

header nav a,
header .nav-link {
    color: var(--nav-text) !important;
}

header nav a:hover,
header .nav-link:hover {
    color: var(--nav-text-hover) !important;
}

/* Material Symbols Font Configuration */
.material-symbols-outlined {
    font-variation-settings:
        'FILL' 0,
        'wght' 400,
        'GRAD' 0,
        'opsz' 24
}

/* Smooth Scrolling */
html {
    scroll-behavior: smooth;
}

/* Form Styles */
input,
select,
textarea {
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

input:focus,
select:focus,
textarea:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(48, 140, 232, 0.1);
}

/* Calendar Styles */
#calendarDays {
    display: contents;
}

.calendar-day {
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 9999px;
    transition: all 0.3s ease;
}

.calendar-day:hover:not(.disabled):not(.other-month) {
    background-color: rgba(48, 140, 232, 0.1);
    color: var(--primary);
}

.calendar-day.selected {
    background-color: var(--primary);
    color: white;
    font-weight: 600;
}

.calendar-day.other-month,
.calendar-day.disabled {
    color: #9ca3af;
    cursor: not-allowed;
}

.dark .calendar-day.other-month,
.dark .calendar-day.disabled {
    color: #4b5563;
}

.calendar-day.disabled {
    opacity: 0.5;
}

/* Time Slot Styles */
button[data-time] {
    transition: all 0.3s ease;
}

button[data-time]:hover:not([disabled]) {
    transform: translateY(-2px);
}

button[data-time].selected {
    background-color: var(--primary);
    color: white;
    border-color: var(--primary);
}

/* Step Counter Animation */
.flex-shrink-0.rounded-full {
    transition: all 0.3s ease;
}

/* Form Section Styles */
.bg-white,
.dark\:bg-background-dark\/30 {
    transition: all 0.3s ease;
}

.bg-white:hover,
.dark\:bg-background-dark\/30:hover {
    border-color: var(--primary);
}

/* Button Styles */
button[type="submit"] {
    transition: all 0.3s ease;
}

button[type="submit"]:hover {
    transform: scale(1.05);
}

button[type="submit"]:active {
    transform: scale(0.98);
}

/* Label Styles */
label {
    transition: color 0.3s ease;
}

input:focus ~ label,
select:focus ~ label,
textarea:focus ~ label {
    color: var(--primary);
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Focus Styles for Accessibility */
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

/* Success Message Animation */
@keyframes slideInDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.success-message {
    animation: slideInDown 0.3s ease;
}

/* Loading State */
.loading {
    opacity: 0.6;
    pointer-events: none;
}

/* Print Styles */
@media print {
    header,
    footer {
        display: none;
    }
    
    .bg-white,
    .dark\:bg-background-dark\/30 {
        page-break-inside: avoid;
        border: 1px solid #000;
    }
}

/* Responsive Adjustments */
@media (max-width: 640px) {
    .max-w-4xl {
        padding: 1rem;
    }
    
    .grid.grid-cols-2 {
        grid-template-columns: 1fr;
    }
}
