/* Checkout Styles - Unique class names to avoid conflicts */

.checkout-card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    box-shadow: 0 8px 32px var(--shadow-light);
    border: 1px solid var(--border-light);
    overflow: hidden;
}

[data-theme="dark"] .checkout-card {
    background: rgba(26, 26, 26, 0.95);
}

.checkout-card-body {
    padding: 2.5rem;
}

.checkout-subtitle {
    font-size: 1.125rem;
    color: #333333;
}

[data-theme="dark"] .checkout-subtitle {
    color: #e5e5e5;
}

/* Main Grid Layout */
.checkout-grid-layout {
    display: grid;
    grid-template-columns: 380px 1fr;
    gap: 2rem;
}

/* Search Column (Left) */
.search-column {
    height: fit-content;
}

.search-section {
    background: rgba(248, 248, 248, 0.5);
    border-radius: 16px;
    padding: 2rem;
    border: 1px solid var(--border-light);
}

[data-theme="dark"] .search-section {
    background: rgba(40, 40, 40, 0.5);
}

.checkout-search-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 1.5rem;
}

[data-theme="dark"] .checkout-search-title {
    color: #f8f9fa;
}

.checkout-field-label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 0.75rem;
    color: #1a1a1a;
}

[data-theme="dark"] .checkout-field-label {
    color: #e5e5e5;
}

.search-input-wrapper {
    position: relative;
    margin-bottom: 1.5rem;
}

.search-icon {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: #666666;
    font-size: 1.1rem;
    z-index: 1;
}

[data-theme="dark"] .search-icon {
    color: #999999;
}

.search-input {
    width: 100%;
    padding: 0.875rem 1rem 0.875rem 3rem !important;
    font-size: 1rem;
    height: auto;
    border-radius: 10px;
    background: #ffffff;
    color: #1a1a1a;
    border: 1px solid #dddddd;
    transition: all 0.3s ease;
}

[data-theme="dark"] .search-input {
    background: rgba(40, 40, 40, 0.8);
    color: #e5e5e5;
    border-color: rgba(244, 208, 63, 0.2);
}

.search-input::placeholder {
    color: #999999;
    opacity: 0.6;
}

.search-input:focus {
    outline: none;
    border-color: var(--primary-gold);
    box-shadow: 0 0 0 3px var(--shadow-light);
}

.error-messages {
    margin-top: 0.75rem;
}

.error-message {
    color: #dc3545;
    font-size: 0.875rem;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
}

.action-buttons {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.btn-cancel,
.btn-continue {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.875rem 1.5rem;
    border-radius: 10px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    font-size: 1rem;
}

.btn-cancel {
    background: #dc3545;
    color: white;
}

.btn-cancel:hover {
    background: #c82333;
    transform: translateY(-2px);
    color: white;
    text-decoration: none;
}

.btn-continue {
    background: linear-gradient(135deg, var(--primary-gold) 0%, var(--secondary-gold) 100%);
    color: white;
}

.btn-continue:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px var(--shadow-medium);
}

/* Visitor Column (Right) */
.visitor-column {
    min-height: 500px;
}

.visitor-details-section {
    background: rgba(255, 255, 255, 0.6);
    border-radius: 16px;
    border: 1px solid var(--border-light);
    overflow: hidden;
}

[data-theme="dark"] .visitor-details-section {
    background: rgba(40, 40, 40, 0.6);
}

.visitor-header {
    background: linear-gradient(135deg, var(--primary-gold) 0%, var(--secondary-gold) 100%);
    padding: 1.25rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.checkout-visitor-header-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1a1a1a !important;
    margin: 0;
}

.status-badge {
    padding: 0.5rem 1.25rem;
    border-radius: 50px;
    font-size: 0.875rem;
    font-weight: 700;
    border: 2px solid;
}

.status-badge.checked-in {
    background: #10b981;
    color: white;
    border-color: #059669;
}

.status-badge.checked-out {
    background: #dc2626;
    color: white;
    border-color: #b91c1c;
}

.visitor-main-content {
    padding: 2rem;
}

.visitor-identity-center {
    text-align: center;
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-light);
}

/* CRITICAL FIX: Visitor photo with visible border */
.checkout-visitor-photo {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    overflow: hidden;
    border: 3px solid #c9a959 !important;
    margin: 0 auto 1rem;
}

[data-theme="dark"] .checkout-visitor-photo {
    border-color: rgba(244, 208, 63, 0.5) !important;
}

.checkout-visitor-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* CRITICAL FIX: Photo placeholder with visible icon */
.checkout-photo-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.2) 0%, rgba(184, 134, 11, 0.2) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #555555 !important;
    font-size: 2.5rem;
}

[data-theme="dark"] .checkout-photo-placeholder {
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.15) 0%, rgba(184, 134, 11, 0.15) 100%);
    color: #aaaaaa !important;
}

/* CRITICAL FIX: Visitor name with high contrast */
.checkout-visitor-display-name {
    font-size: 1.75rem !important;
    font-weight: 700 !important;
    color: #000000 !important;
    margin: 0 !important;
    text-shadow: none !important;
}

[data-theme="dark"] .checkout-visitor-display-name {
    color: #ffffff !important;
}

.visitor-info-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.checkout-info-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: #333333;
    font-size: 0.95rem;
}

[data-theme="dark"] .checkout-info-item {
    color: #e5e5e5;
}

.checkout-info-item i {
    color: var(--primary-gold);
    font-size: 1.1rem;
    width: 20px;
    flex-shrink: 0;
}

.checkout-info-item span {
    flex: 1;
    color: inherit;
}

/* Company & Checkout Box */
.company-checkout-box {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 1.5rem;
    padding: 1.5rem 2rem;
    background: rgba(0, 0, 0, 0.03);
    border-top: 1px solid var(--border-light);
    align-items: center;
}

[data-theme="dark"] .company-checkout-box {
    background: rgba(255, 255, 255, 0.03);
}

.company-details-box {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.checkout-company-name {
    color: var(--primary-gold);
    font-size: 1.125rem;
    font-weight: 700;
    margin: 0 0 0.25rem 0;
}

.checkout-company-address {
    color: #444444;
    font-size: 0.9rem;
    margin: 0 0 0.5rem 0;
    line-height: 1.4;
}

[data-theme="dark"] .checkout-company-address {
    color: #bbbbbb;
}

.checkout-company-contact {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #555555;
    font-size: 0.875rem;
    margin: 0.25rem 0;
}

[data-theme="dark"] .checkout-company-contact {
    color: #aaaaaa;
}

.checkout-company-contact i {
    color: var(--primary-gold);
    width: 16px;
}

.checkout-btn-box {
    text-align: center;
}

.btn-checkout {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    padding: 1rem 2rem;
    border-radius: 12px;
    text-decoration: none;
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.3);
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s ease;
    width: 100%;
}

.btn-checkout:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(16, 185, 129, 0.4);
    color: white;
    text-decoration: none;
}

.btn-checkout i {
    font-size: 1.25rem;
}

.checked-out-msg {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 1rem;
    background: rgba(16, 185, 129, 0.15);
    border-radius: 12px;
    color: #10b981;
    font-weight: 600;
    font-size: 0.9rem;
}

.checked-out-msg i {
    font-size: 1.25rem;
}

/* Placeholder */
.visitor-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 500px;
    background: rgba(0, 0, 0, 0.02);
    border-radius: 16px;
    border: 2px dashed var(--border-light);
}

[data-theme="dark"] .visitor-placeholder {
    background: rgba(255, 255, 255, 0.02);
}

.placeholder-content {
    text-align: center;
    color: #999999;
}

[data-theme="dark"] .placeholder-content {
    color: #666666;
}

.placeholder-content i {
    font-size: 4rem;
    color: #c9a959;
    opacity: 0.3;
    margin-bottom: 1rem;
}

[data-theme="dark"] .placeholder-content i {
    color: var(--primary-gold);
}

.placeholder-content h3 {
    font-size: 1.5rem;
    color: #333333;
    margin-bottom: 0.5rem;
}

[data-theme="dark"] .placeholder-content h3 {
    color: #e5e5e5;
}

.placeholder-content p {
    font-size: 1rem;
    color: #666666;
}

[data-theme="dark"] .placeholder-content p {
    color: #999999;
}

.loading {
    opacity: 0.7;
    pointer-events: none;
}

.form-input.has-value {
    border-color: var(--primary-gold);
    box-shadow: 0 0 0 3px var(--shadow-light);
}

/* Responsive */
@media (max-width: 1024px) {
    .checkout-grid-layout {
        grid-template-columns: 1fr;
    }
    
    .visitor-info-grid {
        grid-template-columns: 1fr;
    }
    
    .company-checkout-box {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .checkout-card-body {
        padding: 1rem;
    }
    
    .search-section {
        padding: 1.5rem;
    }
    
    .visitor-main-content {
        padding: 1.5rem;
    }
    
    .visitor-header {
        flex-direction: column;
        gap: 0.75rem;
    }
}