/* HDW App Styles */

:root {
    /* Halifax Design Week brand palette */
    --hdw-red: #C7333F;
    --hdw-pink: #FF6B8A;
    --hdw-blue: #3D36C7;
    --hdw-teal: #5CC3C9;
    --hdw-sage: #BFD9C6;
    --hdw-yellow: #FFD47A;
    --hdw-black: #000000;
    --hdw-grey: #F2F2F2;

    --primary-color: var(--hdw-red);
    --primary-dark: #9c2732;
    --success-color: #10b981;
    --danger-color: #ef4444;
    --warning-color: #f59e0b;
    --text-color: #1f2937;
    --text-light: #374151;
    --border-color: #e5e7eb;
    --bg-light: #f9fafb;
    --header-bg: #ffffff;
}

body {
    font-family: 'Manrope', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

* {
    box-sizing: border-box;
}

*:focus-visible {
    outline: 3px solid #1d4ed8;
    outline-offset: 2px;
}

body {
    color: var(--text-color);
    line-height: 1.6;
    margin: 0;
    padding: 0;
    background: var(--bg-light);
}

button,
input,
select,
textarea,
.btn,
.profile-btn,
.tab-btn,
.dropdown-item,
.main-nav a,
.nav-link,
.hdw-action-card,
.hdw-sponsor-card {
    min-height: 2.75rem;
}

.skip-link {
    position: absolute;
    left: 1rem;
    top: -3rem;
    background: var(--hdw-blue);
    color: white;
    padding: 0.75rem 1rem;
    border-radius: 0 0 0.5rem 0.5rem;
    z-index: 200;
    text-decoration: none;
    font-weight: 700;
}

.skip-link:focus {
    top: 0;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* App Layout */
.app-container {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.app-header {
    background: var(--header-bg);
    border-bottom: 1px solid var(--border-color);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}

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

.logo {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--primary-color);
    text-decoration: none;
}

.main-nav {
    display: flex;
    gap: 1.5rem;
    align-items: center;
}

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

.main-nav a:hover,
.nav-link:hover {
    color: var(--primary-color);
}

.app-main {
    flex: 1;
}

.app-footer {
    background: var(--header-bg);
    border-top: 1px solid var(--border-color);
    padding: 2rem 1rem;
    text-align: center;
    color: var(--text-light);
}

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

/* Auth Pages */
.auth-container {
    min-height: calc(100vh - 200px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
}

.auth-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    padding: 2rem;
    width: 100%;
    max-width: 440px;
}

.auth-card h1,
.auth-card h2 {
    text-align: center;
    margin-bottom: 1.5rem;
    color: var(--text-color);
}

.auth-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.auth-tabs button {
    flex: 1;
    padding: 0.75rem;
    border: 2px solid var(--border-color);
    background: white;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.2s;
}

.auth-tabs button.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.field-error {
    color: var(--danger-color);
    font-size: 0.875rem;
    line-height: 1.4;
    margin-top: 0.1rem;
}

.form-group label {
    font-weight: 500;
    color: var(--text-color);
}

.form-control {
    padding: 0.75rem;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.2s;
    width: 100%;
    background-color: white;
}

.form-control:focus,
.form-control:focus-visible {
    outline: 3px solid rgba(199, 51, 63, 0.25);
    outline-offset: 2px;
    border-color: var(--primary-color);
}

.form-text {
    font-size: 0.85rem;
}

.text-muted {
    color: var(--text-light);
}

.text-danger {
    color: var(--danger-color);
}

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

/* Buttons */
.btn {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
    display: inline-block;
    text-align: center;
}

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

.btn-primary:hover:not(:disabled) {
    background: var(--primary-dark);
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
}

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

.btn-link {
    background: none;
    color: var(--primary-color);
    border: none;
    text-decoration: underline;
}

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

.btn-danger:hover:not(:disabled) {
    background: #dc2626;
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.btn-lg {
    padding: 1rem 2rem;
    font-size: 1.1rem;
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
}

.w-100 {
    width: 100%;
}

.auth-footer {
    margin-top: 1.5rem;
    text-align: center;
    color: var(--text-light);
}

.auth-footer a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
}

/* Home Page */
.hero-section {
    text-align: center;
    padding: 4rem 1rem;
}

.hero-section h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.hero-section .lead,
.lead {
    font-size: 1.25rem;
    color: var(--text-light);
    margin-bottom: 2rem;
}

.cta-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.welcome-section {
    text-align: center;
    margin-bottom: 3rem;
}

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

.action-card {
    background: white;
    border: 2px solid var(--border-color);
    border-radius: 12px;
    padding: 2rem;
    text-decoration: none;
    color: var(--text-color);
    transition: all 0.2s;
}

.action-card:hover {
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.action-card h3 {
    margin-bottom: 0.5rem;
}

.action-card p {
    color: var(--text-light);
    margin: 0;
}

.features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-top: 4rem;
}

.feature-card {
    text-align: center;
    padding: 1.5rem;
    background: white;
    border-radius: 12px;
}

.feature-card h3 {
    margin-bottom: 0.5rem;
}

.feature-card p {
    color: var(--text-light);
}

/* Alerts */
.alert {
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 1rem;
}

.alert-success {
    background: #d1fae5;
    color: #065f46;
    border: 1px solid #6ee7b7;
}

.alert-danger {
    background: #fee2e2;
    color: #991b1b;
    border: 1px solid #fca5a5;
}

.alert-warning {
    background: #fef3c7;
    color: #92400e;
    border: 1px solid #fcd34d;
}

.alert-info {
    background: #dbeafe;
    color: #1e40af;
    border: 1px solid #93c5fd;
}

/* Loading */
.loading-spinner {
    text-align: center;
    padding: 3rem;
    color: var(--text-light);
}

/* Settings */
.settings-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem 1rem;
}

.settings-header {
    margin-bottom: 2rem;
}

.settings-header h1 {
    margin: 0 0 0.5rem 0;
}

.settings-header p {
    color: var(--text-light);
    margin: 0;
}

.settings-grid {
    display: grid;
    gap: 1.5rem;
}

.detail-card {
    background: white;
    border-radius: 12px;
    padding: 2rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.detail-card h3 {
    margin-top: 0;
    margin-bottom: 1.5rem;
    color: var(--text-color);
}

.detail-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--border-color);
}

.detail-row:last-child {
    border-bottom: none;
}

.detail-label {
    font-weight: 500;
    color: var(--text-light);
}

.detail-value {
    color: var(--text-color);
}

/* Badges */
.badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.85rem;
    font-weight: 500;
}

.badge-success {
    background: #d1fae5;
    color: #065f46;
}

.badge-info {
    background: #dbeafe;
    color: #1e40af;
}

.badge-warning {
    background: #fef3c7;
    color: #92400e;
}

/* Profile Dropdown */
.profile-dropdown {
    position: relative;
}

.profile-btn {
    background: none;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    padding: 0.5rem 1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 500;
    color: var(--text-color);
    transition: all 0.2s;
}

.profile-btn:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.profile-name {
    max-width: 120px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dropdown-arrow {
    font-size: 0.7rem;
}

.profile-dropdown .dropdown-menu {
    position: absolute;
    top: calc(100% + 0.5rem);
    right: 0;
    background: white;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    min-width: 180px;
    z-index: 1000;
    overflow: hidden;
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    color: var(--text-color);
    text-decoration: none;
    border: none;
    background: none;
    width: 100%;
    text-align: left;
    font-size: 1rem;
    cursor: pointer;
    transition: background 0.2s;
}

.dropdown-item:hover {
    background: var(--bg-light);
    color: var(--primary-color);
}

/* Responsive */
@media (max-width: 768px) {
    .hero-section h1 {
        font-size: 2rem;
    }

    .header-content {
        flex-direction: column;
        gap: 1rem;
    }

    .main-nav {
        flex-wrap: wrap;
        justify-content: center;
    }

    .cta-buttons {
        flex-direction: column;
    }

    .quick-actions {
        grid-template-columns: 1fr;
    }
}

/* ---------------------------------------------------------------------- */
/* Halifax Design Week – Home page                                        */
/* ---------------------------------------------------------------------- */

.hdw-hero {
    text-align: center;
    padding: 2.5rem 1rem 1.5rem;
}

.hdw-hero h1 {
    font-family: 'Bebas Neue', 'Manrope', sans-serif;
    font-size: 2.75rem;
    letter-spacing: 0.02em;
    margin: 0 0 0.25rem;
    color: var(--hdw-black);
}

.hdw-tagline {
    color: var(--hdw-red);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin: 0 0 1rem;
}

.hdw-main-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    padding: 0 1rem;
    max-width: 700px;
    margin: 0 auto;
    list-style: none;
}

.hdw-action-item {
    list-style: none;
    margin: 0;
    padding: 0;
}

.hdw-action-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    padding: 2rem 1rem;
    border-radius: 16px;
    text-decoration: none;
    color: white;
    text-align: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
    transition: transform 0.15s ease;
}

.hdw-action-card:hover {
    transform: translateY(-3px);
}

.hdw-action-program {
    background: linear-gradient(135deg, var(--hdw-red), var(--hdw-pink));
}

.hdw-action-map {
    background: linear-gradient(135deg, var(--hdw-blue), var(--hdw-teal));
}

.hdw-action-icon {
    font-size: 2rem;
}

.hdw-action-title {
    font-size: 1.25rem;
    font-weight: 700;
}

.hdw-action-subtitle {
    font-size: 0.85rem;
    opacity: 0.9;
}

.hdw-feedback-link {
    text-align: center;
    margin: 1.5rem 0 2.5rem;
}

.hdw-feedback-link a {
    color: var(--text-light);
    text-decoration: none;
    font-size: 0.95rem;
}

.hdw-feedback-link a:hover {
    color: var(--primary-color);
}

.hdw-sponsors {
    border-top: 1px solid var(--border-color);
    padding: 2rem 1rem;
    text-align: center;
}

.hdw-sponsors h2 {
    font-size: 1.1rem;
    color: var(--text-light);
    margin-bottom: 1.25rem;
}

.hdw-sponsor-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.25rem;
    list-style: none;
    padding: 0;
    margin: 0 auto;
}

.hdw-sponsor-item {
    list-style: none;
}

.hdw-sponsor-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.4rem;
    text-decoration: none;
    color: var(--text-color);
    width: 100px;
}

.hdw-sponsor-logo {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.9rem;
}

.hdw-sponsor-name {
    font-size: 0.75rem;
    text-align: center;
}

.hdw-app-credit {
    margin-top: 1.75rem;
    font-size: 0.85rem;
    color: var(--text-light);
}

.hdw-app-credit a {
    color: var(--primary-color);
    font-weight: 600;
    text-decoration: none;
}

/* ---------------------------------------------------------------------- */
/* Program / Event cards                                                   */
/* ---------------------------------------------------------------------- */

.program-header h1,
.detail-content h1 {
    margin-bottom: 0.25rem;
}

.program-tabs {
    display: flex;
    gap: 0.5rem;
    margin: 1rem 0 1.5rem;
}

.tab-btn {
    flex: 1;
    padding: 0.65rem;
    border: 2px solid var(--border-color);
    background: white;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.2s;
}

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

.program-day-heading {
    margin: 2rem 0 1rem;
    font-size: 1.15rem;
    color: var(--hdw-blue);
}

.event-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 1.25rem;
    list-style: none;
    padding: 0;
    margin: 0;
}

.event-card-item {
    list-style: none;
}

.event-card {
    display: flex;
    flex-direction: column;
    background: white;
    border-radius: 12px;
    overflow: hidden;
    color: var(--text-color);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
    height: 100%;
}

.event-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.12);
}

.event-card-link {
    color: var(--text-color);
    text-decoration: none;
}

.event-card-link:hover,
.event-card-link:focus-visible {
    color: var(--primary-color);
}

.event-card-image {
    height: 140px;
    background-size: cover;
    background-position: center;
    background-color: var(--hdw-grey);
}

.event-card-body {
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.event-card-body h3 {
    margin: 0.15rem 0;
    font-size: 1.05rem;
}

.event-card-time,
.event-card-location {
    margin: 0;
    font-size: 0.85rem;
    color: var(--text-light);
}

.badge-category {
    align-self: flex-start;
    background: var(--hdw-blue);
    color: white;
}

/* ---------------------------------------------------------------------- */
/* Event / Venue details                                                   */
/* ---------------------------------------------------------------------- */

.back-link {
    padding-left: 0;
    margin-bottom: 1rem;
}

.detail-hero {
    height: 240px;
    border-radius: 16px;
    background-size: cover;
    background-position: center;
    background-color: var(--hdw-grey);
    margin-bottom: 1.5rem;
}

.detail-content h1 {
    margin-top: 0.5rem;
}

.detail-meta {
    color: var(--text-light);
    margin: 0.25rem 0;
}

.detail-description {
    margin: 1.25rem 0;
    line-height: 1.7;
}

.detail-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-top: 1rem;
}

/* ---------------------------------------------------------------------- */
/* Map page                                                                 */
/* ---------------------------------------------------------------------- */

.map-filters {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.map-filter {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-weight: 500;
    cursor: pointer;
}

.pin-swatch {
    display: inline-block;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    border: 2px solid white;
    box-shadow: 0 0 0 1px var(--border-color);
}

.pin-anchor {
    background: var(--hdw-red);
    width: 18px;
    height: 18px;
}

.pin-satellite {
    background: var(--hdw-blue);
}

.map-canvas {
    width: 100%;
    height: 60vh;
    min-height: 360px;
    border-radius: 16px;
    background: var(--hdw-grey);
}

/* Responsive: Halifax Design Week pages (mobile-first; scale up on larger screens) */
@media (min-width: 769px) {
    .hdw-main-actions {
        max-width: 900px;
    }

    .map-canvas {
        height: 70vh;
    }
}

@media (max-width: 640px) {
    .hdw-main-actions {
        grid-template-columns: 1fr;
    }

    .hdw-hero h1 {
        font-size: 2.1rem;
    }

    .event-list {
        grid-template-columns: 1fr;
    }
}

