/* Camera Overlay Styles */
.camera-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--gray-900);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 3000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.camera-overlay.active {
    opacity: 1;
    visibility: visible;
}

.camera-card {
    width: 100%;
    max-width: 480px;
    height: 100%;
    max-height: 800px;
    background: var(--gray-900);
    display: flex;
    flex-direction: column;
}

.camera-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.5rem;
    background: rgba(0, 0, 0, 0.5);
}

.camera-header h3 {
    color: var(--white);
    font-size: 1.125rem;
    font-weight: 600;
}

.close-camera-btn {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all var(--transition);
}

.close-camera-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

.close-camera-btn svg {
    width: 24px;
    height: 24px;
    color: var(--white);
}

/* Camera Container */
.camera-container {
    flex: 1;
    position: relative;
    overflow: hidden;
    background: #000;
}

#camera-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

#camera-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* Camera Frame Guide */
.camera-frame {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 280px;
    height: 350px;
    border: 2px dashed rgba(255, 255, 255, 0.5);
    border-radius: var(--radius-xl);
    pointer-events: none;
}

.frame-corner {
    position: absolute;
    width: 30px;
    height: 30px;
    border-color: var(--primary-500);
    border-style: solid;
}

.frame-corner.top-left {
    top: -1px;
    left: -1px;
    border-width: 4px 0 0 4px;
    border-radius: var(--radius-lg) 0 0 0;
}

.frame-corner.top-right {
    top: -1px;
    right: -1px;
    border-width: 4px 4px 0 0;
    border-radius: 0 var(--radius-lg) 0 0;
}

.frame-corner.bottom-left {
    bottom: -1px;
    left: -1px;
    border-width: 0 0 4px 4px;
    border-radius: 0 0 0 var(--radius-lg);
}

.frame-corner.bottom-right {
    bottom: -1px;
    right: -1px;
    border-width: 0 4px 4px 0;
    border-radius: 0 0 var(--radius-lg) 0;
}

.frame-guide-text {
    position: absolute;
    bottom: -35px;
    left: 50%;
    transform: translateX(-50%);
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.8125rem;
    white-space: nowrap;
}

/* Photo Preview */
.photo-preview {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #000;
}

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

/* Camera Controls */
.camera-controls {
    padding: 2rem;
    display: flex;
    justify-content: center;
    background: rgba(0, 0, 0, 0.5);
}

.capture-btn {
    width: 80px;
    height: 80px;
    background: transparent;
    border: 4px solid var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all var(--transition);
}

.capture-btn:hover {
    transform: scale(1.05);
}

.capture-btn:active {
    transform: scale(0.95);
}

.capture-circle {
    width: 64px;
    height: 64px;
    background: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.capture-inner {
    width: 52px;
    height: 52px;
    background: var(--primary-500);
    border-radius: 50%;
    transition: all 0.2s ease;
}

.capture-btn:active .capture-inner {
    transform: scale(0.9);
}

/* Camera Instruction */
.camera-instruction {
    text-align: center;
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9375rem;
    padding: 0 1rem 1.5rem;
    margin: 0;
    background: rgba(0, 0, 0, 0.5);
}

/* Camera Actions */
.camera-actions {
    display: flex;
    gap: 1rem;
    padding: 1rem 1.5rem 2rem;
    background: rgba(0, 0, 0, 0.5);
}

.retake-btn,
.confirm-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.875rem 1rem;
    border: none;
    border-radius: var(--radius-lg);
    font-size: 0.9375rem;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition);
}

.retake-btn {
    background: rgba(255, 255, 255, 0.1);
    color: var(--white);
}

.retake-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

.retake-btn svg {
    width: 20px;
    height: 20px;
}

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

.confirm-btn:hover {
    background: var(--primary-600);
}

.confirm-btn svg {
    width: 20px;
    height: 20px;
}

/* Responsive for Camera */
@media (max-width: 480px) {
    .camera-card {
        max-height: 100vh;
    }
    
    .camera-frame {
        width: 240px;
        height: 300px;
    }
    
    .capture-btn {
        width: 70px;
        height: 70px;
    }
    
    .capture-circle {
        width: 56px;
        height: 56px;
    }
    
    .capture-inner {
        width: 44px;
        height: 44px;
    }
}

/* Dark mode for camera */
@media (prefers-color-scheme: dark) {
    .camera-overlay {
        background: var(--gray-900);
    }
}
