/* LizLevels - Shared Styles */

html, body {
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background: #1a1a2e;
    height: 100%;
    overflow: hidden;
}

/* Platform-specific body classes */
.platform-web {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding: 2rem;
    overflow: auto;
    height: auto;
    min-height: 100vh;
}

.platform-web .app-container {
    height: auto;
    width: 500px;
    background: #1a1a2e;
}

.platform-web .volume-page {
    background: #1e1e32;
    border-radius: 16px;
    height: auto;
}

.platform-web .volume-container {
    height: 50px;
}

.platform-maui {
    /* MAUI-specific styles */
}

/* Volume Bar Component */
.volume-container {
    position: relative;
    width: 100%;
    min-height: 50px;
    border-radius: 12px;
    overflow: hidden;
    transition: background-color 0.2s ease;
    flex-shrink: 0;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.2);
}

.volume-container.level-green {
    background-color: #1a2e1a;
}

.volume-container.level-yellow {
    background-color: #2e2a1a;
}

.volume-container.level-red {
    background-color: #2e1a1a;
}

.volume-bar {
    height: 100%;
    border-radius: 12px;
    transition: width 0.05s ease-out, background-color 0.2s ease;
}

.level-green .volume-bar {
    background: linear-gradient(90deg, #22c55e, #4ade80);
}

.level-yellow .volume-bar {
    background: linear-gradient(90deg, #eab308, #facc15);
}

.level-red .volume-bar {
    background: linear-gradient(90deg, #ef4444, #f87171);
}

.volume-label {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 1.1rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.9);
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
    letter-spacing: 0.02em;
}

.volume-label.warning-flash {
    color: #fff;
    text-shadow: 0 0 15px rgba(239, 68, 68, 0.9), 0 0 30px rgba(239, 68, 68, 0.5);
    animation: pulse 0.5s ease-in-out infinite alternate;
}

.volume-label .calibrating {
    color: #94a3b8;
    font-size: 0.95rem;
}

@keyframes pulse {
    from {
        opacity: 0.7;
    }
    to {
        opacity: 1;
    }
}

/* App Container */
.app-container {
    display: flex;
    flex-direction: column;
    height: 100vh;
    box-sizing: border-box;
}

.app-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

/* Volume Page */
.volume-page {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: 1rem;
    height: 100%;
    width: 100%;
    box-sizing: border-box;
}

.volume-content {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    flex: 1;
    min-height: 0;
    width: 100%;
}

.volume-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: #e2e8f0;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.app-logo {
    height: 28px;
    width: auto;
}

.header-btn {
    color: #64748b !important;
}

.header-btn:hover {
    color: #e2e8f0 !important;
}

.settings-btn {
    margin-left: auto;
}

.settings-dialog {
    padding: 1rem;
}

.threshold-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 6px;
}

.calibration-step {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    padding: 0.75rem;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
}

/* Volume History */
.volume-history {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 12px;
    padding: 0.75rem;
    height: 180px;
    flex-shrink: 0;
}

.history-header {
    color: #64748b;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.history-bars {
    display: flex;
    align-items: flex-end;
    flex: 1;
    gap: 2px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 8px;
    padding: 8px;
}

.history-bar {
    flex: 1;
    min-width: 2px;
    min-height: 2px;
    background: #4ade80;
    border-radius: 2px;
    opacity: 0.8;
}

.history-stats {
    display: flex;
    justify-content: space-between;
    font-family: monospace;
    font-size: 0.75rem;
    color: #64748b;
}

/* Calibration Prompt */
.calibration-prompt {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 12px;
    padding: 0.75rem;
    flex: 1;
    min-height: 0;
    overflow: auto;
}

.calibration-prompt-header {
    color: #4ade80;
    font-size: 0.85rem;
    font-weight: 500;
}

.calibration-prompt-text {
    color: #94a3b8;
    font-size: 0.9rem;
    font-style: italic;
    line-height: 1.6;
}

/* Landing Page (Web only) */
.landing-page {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2rem;
}

.landing-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    padding: 2.5rem;
    max-width: 500px;
    width: 100%;
}

.landing-logo {
    height: 48px;
    width: auto;
}

.landing-tagline {
    color: #94a3b8;
    text-align: center;
    margin: 0;
    font-size: 1.1rem;
}

.landing-options {
    display: flex;
    gap: 1rem;
    width: 100%;
    margin-top: 0.5rem;
}

.landing-option {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    padding: 1.25rem 1rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    color: #e2e8f0;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease;
}

.landing-option:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.option-icon {
    font-size: 2rem;
}

.option-title {
    font-weight: 600;
    font-size: 1rem;
}

.option-desc {
    font-size: 0.8rem;
    color: #64748b;
    text-align: center;
}

.landing-footer {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    width: 100%;
    display: flex;
    justify-content: center;
}

.github-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #64748b;
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.2s ease;
}

.github-link:hover {
    color: #e2e8f0;
}
