/* ======================
   LAYOUT - Header, Footer, Main Structure
   ====================== */

/* HEADER */
.header {
    position: relative;
    z-index: 100;
    background: linear-gradient(135deg, #000000 0%, #1A1A1A 100%);
    color: var(--color-primary);
    box-shadow: 0 4px 12px rgba(201, 168, 106, 0.3);
    border-bottom: 2px solid var(--color-primary);
    padding-top: var(--safe-area-top);
}

.header-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: var(--spacing-md);
}

.header-top {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-md);
}

.logo-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-sm);
    flex-shrink: 0;
}

.logo {
    width: 228px;
    height: 228px;
    border-radius: var(--radius-md);
    background-color: transparent;
    padding: 0;
    box-shadow: var(--shadow-md);
    object-fit: contain;
}

.business-info {
    display: none;
}

.business-name {
    font-family: var(--font-heading);
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: var(--color-primary);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.business-tagline {
    font-size: 13px;
    color: #DC143C;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.header-contact {
    display: flex;
    flex-direction: column;
    gap: 8px;
    font-size: 13px;
    color: var(--color-text-dark);
    text-align: center;
    line-height: 1.4;
    margin-top: var(--spacing-md);
}

.header-contact-item {
    display: flex;
    align-items: center;
    gap: 6px;
    justify-content: center;
}

.header-contact-icon {
    font-size: 12px;
    color: var(--color-primary);
}

.header-contact a {
    color: var(--color-text-dark);
    text-decoration: none;
}

.header-contact a:hover {
    color: var(--color-primary);
}

/* SEARCH */
.search-container {
    position: sticky;
    top: 0;
    z-index: 999;
    background: linear-gradient(135deg, #000000 0%, #1A1A1A 100%);
    padding: var(--spacing-md);
    border-bottom: 2px solid var(--color-primary);
    box-shadow: 0 4px 12px rgba(201, 168, 106, 0.3);
}

.search-wrapper {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
}

.search-input {
    width: 100%;
    padding: var(--spacing-sm) var(--spacing-md);
    padding-left: 40px;
    padding-right: 50px; /* Space for clear button */
    border: 2px solid var(--color-border);
    border-radius: var(--radius-lg);
    font-size: 16px;
    font-family: var(--font-body);
    background-color: var(--color-surface);
    color: var(--color-text-dark);
    box-shadow: var(--shadow-sm);
    transition: all 0.2s;
}

/* Remove default browser search controls (X button, magnifying glass) */
.search-input::-webkit-search-decoration,
.search-input::-webkit-search-cancel-button,
.search-input::-webkit-search-results-button,
.search-input::-webkit-search-results-decoration {
    -webkit-appearance: none;
    appearance: none;
    display: none;
}

/* Remove Edge/IE clear button */
.search-input::-ms-clear,
.search-input::-ms-reveal {
    display: none;
    width: 0;
    height: 0;
}

.search-input:focus {
    outline: none;
    background-color: var(--color-surface);
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(201, 168, 106, 0.2);
}

.search-icon {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--color-primary);
    pointer-events: none;
    z-index: 1;
}

.clear-search-btn {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
    padding: 0;
    z-index: 10;
    border-radius: 50%;
}

.clear-search-btn:hover {
    background: rgba(201, 168, 106, 0.2);
    transform: translateY(-50%) scale(1.15);
}

.clear-search-btn:active {
    transform: translateY(-50%) scale(0.9);
    background: rgba(201, 168, 106, 0.3);
}

.clear-search-btn svg {
    width: 20px;
    height: 20px;
    stroke: var(--color-primary);
    stroke-width: 2.5;
}

/* Mobile optimization for clear button */
@media (max-width: 768px) {
    .clear-search-btn {
        width: 32px;
        height: 32px;
        right: 10px;
    }
    
    .clear-search-btn svg {
        width: 22px;
        height: 22px;
        stroke-width: 3;
    }
    
    .clear-search-btn:hover {
        background: rgba(201, 168, 106, 0.25);
    }
}

/* MAIN CONTAINER */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: var(--spacing-lg) var(--spacing-md);
    padding-bottom: calc(72px + var(--safe-area-bottom) + var(--spacing-lg));
}

.loading,
.empty-state,
.error-state {
    text-align: center;
    padding: var(--spacing-xl) var(--spacing-md);
}

.loading-spinner {
    width: 48px;
    height: 48px;
    border: 4px solid var(--color-border);
    border-top-color: var(--color-primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto var(--spacing-md);
}

.empty-icon {
    font-size: 64px;
    margin-bottom: var(--spacing-md);
}

.empty-title {
    font-family: var(--font-heading);
    font-size: 20px;
    font-weight: 600;
    color: var(--color-text-dark);
    margin-bottom: var(--spacing-sm);
}

.empty-text {
    color: var(--color-text-medium);
    font-size: 14px;
}

/* FOOTER */
.sticky-footer {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 90;
    background: linear-gradient(180deg, transparent 0%, rgba(10, 10, 10, 0.95) 20%);
    backdrop-filter: blur(10px);
    padding: var(--spacing-md);
    padding-bottom: calc(var(--spacing-md) + var(--safe-area-bottom));
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-md);
}

/* CONTACT INFO MOBILE BANNER */
.contact-info {
    background: linear-gradient(135deg, #1A1A1A 0%, #0A0A0A 100%);
    border-bottom: 1px solid var(--color-primary);
    padding: var(--spacing-sm) var(--spacing-md);
    font-size: 12px;
}

.contact-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--color-text-dark);
}

.contact-icon {
    font-size: 14px;
    color: var(--color-primary);
    flex-shrink: 0;
}

.contact-text {
    font-size: 12px;
    line-height: 1.4;
}

.contact-text a {
    color: var(--color-text-dark);
    text-decoration: none;
    transition: color 0.2s;
}

.contact-text a:hover {
    color: var(--color-primary);
}

/* RESPONSIVE */
@media (min-width: 640px) {
    .logo {
        width: 286px;
        height: 286px;
    }
    
    .header-contact {
        font-size: 14px;
        gap: 10px;
    }
    
    .header-contact-item {
        gap: 8px;
    }
    
    .header-contact {
        display: flex;
    }
    
    .contact-info {
        display: none;
    }
    
    .business-name {
        font-size: 24px;
    }
    
    .business-tagline {
        font-size: 14px;
    }
    
    .footer-content {
        gap: var(--spacing-lg);
    }
}

@media (min-width: 1024px) {
    .container {
        max-width: 900px;
    }
}
