/* Daily Visibility */

/* Daily Visibility Timeline */
.timeline-container {
    position: relative;
    width: 100%;
    height: 200px;
    margin: 2rem 0;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
}

.timeline-gradient {
    width: 100%;
    height: 100%;
    display: block;
}

.timeline-marker-label {
    position: absolute;
    top: 10px;
    left: 5px;
    font-size: 0.75rem;
    font-weight: 500;
    white-space: nowrap;
    padding: 2px 6px;
    background: rgba(0, 0, 0, 0.7);
    border-radius: 3px;
}

.timeline-labels {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 30px;
    display: flex;
    align-items: flex-end;
    padding: 0 1px;
}


/* Daily Visibilty Info */
.detail-item {
    display: flex;
    justify-content: space-between;
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--border-color);
}

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

.detail-label {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.detail-value {
    color: var(--text-color);
    font-weight: 500;
    font-size: 0.9rem;
}

/* Controls row */
.dv-controls-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    padding: 4px 4px;
    margin-top: 12px;
    margin-bottom: 0;
}

.dv-controls-row .btn-sm {
    padding: 1px 5px;
    border: 3px solid var(--border-color);
}

#dv-prev-week, #dv-prev-day {
    margin-right: 0;
}

#dv-prev-day {
    margin-right: 2px;
}

#dv-next-day, #dv-next-week {
    margin-left: 0;
}

#dv-next-day {
    margin-left: 2px;
}

#dv-next-week {
    margin-right: 1rem;
}

#dv-use-horizon {
    margin-left: 1rem;
}

.dv-label {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.dv-date-input {
    font-size: 0.85rem;
    padding: 2px 4px;
    background: var(--input-bg);
    color: var(--text-color);
    border: 1px solid var(--border-color);
    border-radius: 4px;
}

.dv-select {
    font-size: 0.85rem;
    padding: 2px 4px;
    background: var(--input-bg);
    color: var(--text-color);
    border: 1px solid var(--border-color);
    border-radius: 4px;
}

#dv-min-alt-dropdown {
    min-width: 60px;
    max-width: 60px;
    display: inline-block;
    vertical-align: middle;
}

/* Legend */
.legend-svg {
    vertical-align: middle;
}

.legend-dark {
    background: #000;
}

.legend-dim {
    background: #666;
}

.legend-bright {
    background: #fff;
}

#analysis-title {
    margin-bottom: 0;
    font-size: 1.3rem;
    color: var(--text-secondary);
}

/* Info cards */

/* Make info cards more compact */
.info-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.2rem;
    margin: 1.5rem 0;
}

.info-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 1rem;
    position: relative;
}

.info-value {
    font-size: 0.9rem;
    color: var(--text-secondary);
    font-weight: normal;
}

.info-subtext {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-top: 0.25rem;
}

/* Info card text sizing and spacing to match original */
.info-card h3 {
    margin: 0 0 10px 0;
    color: var(--accent-primary);
    font-size: 1rem;
    font-weight: 600;
}

.info-card-content {
    color: var(--text-color);
}

/* Section labels and values */
.info-section {
    margin-top: 10px;
}

.info-label {
    font-size: 1em;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 3px;
}

.dv-separation-dawn {
    margin-top: 15px;
}

/* Altitude override indicator (kept for modal compatibility) */
.altitude-override-indicator {
    display: inline-block;
    width: 30px;
    text-align: center;
    cursor: pointer;
    color: var(--warning-color);
    font-size: 1.2rem;
    visibility: hidden;
}

.altitude-override-indicator.visible {
    visibility: visible;
}

/* ============================================================
   Daily Visibility View Styles
   ============================================================ */

.visibility-view h2 {
    margin-bottom: 1.0rem;
}

.timeline-marker {
    position: absolute;
    top: 0;
    transform: translateX(-50%);
    text-align: center;
    z-index: 10;
}

.marker-icon {
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 1.2rem;
    margin-bottom: 0.25rem;
}

.marker-time {
    font-size: 0.75rem;
    font-weight: 600;
}

.timeline-labels-row {
    display: flex;
    justify-content: space-between;
    margin-top: 0.5rem;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.timeline-label {
    position: absolute;
    transform: translateX(-50%);
    font-size: 0.75rem;
}

.gradient-legend {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-top: 1rem;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.85rem;
}

.legend-color {
    width: 30px;
    height: 20px;
    border: 1px solid var(--border-color);
    border-radius: 3px;
}

.gradient-legend #legend-target-altitude {
    width: 30px;
    height: 5px;
    background: #ffffff;
    border: 1px solid #000000;
    border-radius: 1px;
}

.gradient-legend #legend-minimum-altitude {
    width: 30px;
    height: 5px;
    background: repeating-linear-gradient(to right, #ffffff 0, #ffffff 5px, transparent 5px, transparent 10px);
    border: 1px solid #000000;
    border-radius: 1px;
}

.time-marker::before {
    content: attr(data-icon);
    position: absolute;
    top: 5px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 20px;
    background: rgba(0, 0, 0, 0.8);
    color: #ffffff;
    padding: 4px;
    border-radius: 4px;
    white-space: nowrap;
    width: 50px;
    text-align: center;
    box-sizing: border-box;
}

.time-marker::after {
    content: attr(data-time);
    position: absolute;
    top: 35px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 14px;
    color: #ffc107;
    white-space: nowrap;
    background: rgba(0, 0, 0, 0.9);
    padding: 3px 6px;
    border-radius: 3px;
    border: 1px solid rgba(255, 193, 7, 0.3);
    width: 50px;
    text-align: center;
    box-sizing: border-box;
}

.time-marker[data-icon*="🌙"]::before {
    top: 95px;
}

.time-marker[data-icon*="🌙"]::after {
    top: 125px;
}

.time-marker[data-icon*="✨"]::before {
    top: 190px;
}

.time-marker[data-icon*="✨"]::after {
    top: 220px;
}

#separation-dusk, #separation-dawn {
    display: inline;
    margin-left: 0.25rem;
    font-size: 1em;
    color: var(--text-color);
}

#separation-dusk-desc, #separation-dawn-desc {
    display: block;
    margin-top: 0.25rem;
    font-size: 0.88em;
    color: var(--text-secondary);
    line-height: 1.3;
}

#timeline-section h3 {
    text-align: center;
    margin-bottom: 0;
}

.timeline-legend {
    display: flex;
    gap: 2rem;
    justify-content: center;
    margin: 1rem 0;
    font-size: 1rem;
    color: var(--text-secondary);
}

.timeline-legend span {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.timeline-legend span::before {
    font-size: 1.3rem;
}

#timeline-section {
    margin-top: 0;
    width: 100%;
}

.timeline-visualization {
    position: relative;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 0 0;
    margin: 0 0;
    min-height: 150px;
    width: 100%;
}

.moon-phase-display {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 10px;
}

#moon-phase-name {
    font-size: 1rem;
    font-weight: normal;
    color: var(--text-color);
    margin-bottom: 2px;
}

#moon-illumination {
    font-size: 0.88em;
    color: var(--text-secondary);
}

.moon-emoji {
    font-size: 2.8em;
    line-height: 1;
}

#dv-moon-details::before {
    content: attr(data-emoji);
    position: absolute;
    top: 8px;
    right: 12px;
    font-size: 4rem;
    opacity: 0.12;
    pointer-events: none;
    line-height: 1;
}

#dv-target-details::before {
    content: '✨';
    position: absolute;
    top: 8px;
    right: 12px;
    font-size: 4rem;
    opacity: 0.12;
    pointer-events: none;
    line-height: 1;
}

#dv-moon-separation::before {
    content: '';
    position: absolute;
    inset: 0;
    opacity: 0.2;
    pointer-events: none;
background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 150'%3E%3Ccircle cx='100' cy='85' r='28' fill='none' stroke='%23888888' stroke-width='4'/%3E%3Ccircle cx='190' cy='15' r='10' fill='none' stroke='%23888888' stroke-width='3'/%3E%3Cpath d='M118 60 Q175 55 181 24' fill='none' stroke='%23888888' stroke-width='2.5' stroke-dasharray='5 4'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center;
    background-size: 90%;
}

#target-altitude,
.info-subtext {
    font-size: 0.88em;
    color: var(--text-secondary);
    margin-bottom: 2px;
    line-height: 1.3;
}

#moon-rise-set,
#target-rise-set,
.info-value {
    font-size: 0.88em;
    color: var(--text-secondary);
    line-height: 1.4;
}

#separation-dusk .info-label,
#separation-dawn .info-label {
    font-weight: normal;
}


/* ============================================================
   Cloud Cover Strip — Issue #81
   ============================================================ */

.cloud-cover-strip {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 137px;
    z-index: 5;
    border-radius: 8px 8px 0 0;
    overflow: hidden;
}

.cloud-band {
    position: relative;
    width: 100%;
    height: 45px;
}

.cloud-band-gap {
    width: 100%;
    height: 1px;
    background: rgba(128, 128, 128, 0.3);
}

.cloud-band-label {
    position: absolute;
    left: 4px;
    bottom: 2px;
    font-family: monospace;
    font-size: 9px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.6);
    z-index: 6;
    line-height: 1;
    pointer-events: none;
    background: rgba(0, 0, 0, 0.8);
    padding: 1px 3px;
    border-radius: 2px;
}

.cloud-band-label-title {
    font-size: 15px;
}

.cloud-band-desc {
    left: 18px;
    font-weight: 400;
    white-space: nowrap;
}

.cloud-unavailable {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 137px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.6);
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.4);
    font-style: italic;
    z-index: 5;
    border-radius: 8px 8px 0 0;
}
