/* Weather Display Styles v1.1.2 */
.weather-current-container {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
    max-width: 425px;
    background: #fff;
    padding: 8px;
    box-sizing: border-box;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.weather-current-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    height: 100%;
}

.weather-column.primary-conditions {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding-right: 10px;
    border-right: 1px solid #eee;
}

.weather-meta {
    text-align: center;
    margin-bottom: 2px;
}

.location-name {
    font-size: 0.95em;
    font-weight: 600;
    color: #2c3e50;
    margin: 0;
}

.weather-icon-large {
    text-align: center;
    margin: 0;
}

.weather-icon {
    width: 48px;
    height: 48px;
    display: block;
    margin: 0 auto;
}

.current-temp-large {
    text-align: center;
}

.temp-main {
    font-size: 1.8em;
    font-weight: 500;
    color: #2c3e50;
    line-height: 1;
    margin: 0;
}

.weather-description {
    font-size: 0.8em;
    color: #34495e;
    margin-top: 2px;
}

.feels-like {
    text-align: center;
    font-size: 0.8em;
    color: #7f8c8d;
    margin-top: 2px;
}

.weather-column.temp-details {
    display: flex;
    flex-direction: column;
    gap: 4px;
    position: relative;
    height: 100%;
}

.weather-column.temp-details h3 {
    font-size: 0.85em;
    font-weight: 600;
    color: #2c3e50;
    margin: 0 0 4px;
    padding-bottom: 3px;
    border-bottom: 1px solid #eee;
}

.weather-column.temp-details .weather-timestamp {
    font-size: 0.7em;
    color: #95a5a6;
    margin-top: auto;
    padding-top: 4px;
    border-top: 1px solid #eee;
}

.weather-detail {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 2px 0;
}

.detail-label {
    font-size: 0.75em;
    color: #7f8c8d;
}

.detail-value {
    font-size: 0.85em;
    font-weight: 500;
    color: #2c3e50;
}

.temp-high {
    color: #e74c3c;
}

.temp-low {
    color: #3498db;
}

.weather-header {
    margin-bottom: 12px;
    text-align: center;
}

.weather-grid {
    display: flex;
    gap: 20px;
    flex: 1;
    margin-bottom: 12px;
}

.weather-column.primary-conditions {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding-right: 20px;
    border-right: 1px solid #eee;
    min-width: 140px;
}

.weather-icon-wrapper {
    text-align: center;
}

.weather-icon {
    width: 64px;
    height: 64px;
    display: block;
}

.current-temp {
    text-align: center;
}

.temp-main {
    font-size: 2.2em;
    font-weight: 500;
    color: #2c3e50;
    line-height: 1.1;
    margin: 0;
}

.weather-description {
    font-size: 0.9em;
    color: #34495e;
    margin-top: 4px;
}

.weather-column.temp-details {
    display: flex;
    flex-direction: column;
    
    flex: 1;
}

.weather-detail {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 4px 0;
}

.detail-label {
    font-size: 0.9em;
    color: #7f8c8d;
}

.detail-value {
    font-size: 1em;
    font-weight: 500;
    color: #2c3e50;
}

.temp-high {
    color: #e74c3c;
}

.temp-low {
    color: #3498db;
}

.weather-footer {
    margin-top: auto;
    text-align: center;
    padding-top: 8px;
    border-top: 1px solid #eee;
}

.weather-timestamp {
    font-size: 0.75em;
    color: #95a5a6;
}

.location-name {
    font-size: 1.1em;
    font-weight: 600;
    color: #2c3e50;
    margin: 0;
}

.weather-content-wrapper {
    display: flex;
    gap: 12px;
    flex: 1;
}

.weather-current-primary {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding-right: 12px;
    border-right: 1px solid #eee;
    min-width: 140px;
}

.location-name {
    font-size: 1em;
    font-weight: 500;
    color: #2c3e50;
    margin: 0;
    text-align: center;
    padding-bottom: 4px;
    border-bottom: 1px solid #eee;
}

.weather-icon-wrapper {
    text-align: center;
    padding: 2px 0;
}

.weather-icon {
    width: 60px;
    height: 60px;
    display: block;
    margin: 0 auto;
}

.weather-current-temp {
    text-align: center;
    flex: 1;
}

.temp-main {
    font-size: 1.8em;
    font-weight: 500;
    color: #2c3e50;
    line-height: 1;
    margin: 0;
}

.weather-description {
    font-size: 0.85em;
    color: #34495e;
    margin-top: 4px;
}

.weather-timestamp {
    font-size: 0.7em;
    color: #7f8c8d;
    text-align: center;
    padding-top: 4px;
    border-top: 1px solid #eee;
    margin-top: auto;
}

.weather-current-details {
    display: flex;
    flex-direction: column;
    gap: 6px;
    flex: 1;
    padding: 2px 0;
}

.weather-detail {
    display: flex;
    align-items: center;

    padding: 2px 0;
}

.detail-icon {
    width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.detail-icon img {
    width: 14px;
    height: 14px;
    opacity: 0.7;
}

.detail-content {
    display: flex;
    flex-direction: column;
    gap: 1px;
}

.detail-label {
    font-size: 0.75em;
    color: #7f8c8d;
    line-height: 1;
}

.detail-value {
    font-size: 0.9em;
    font-weight: 400;
    color: #2c3e50;
    line-height: 1;
}

.weather-alerts {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid #eee;
}

.weather-alert {
    display: flex;
    align-items: center;
    padding: 12px;
    background: #fff3cd;
    border: 1px solid #ffeeba;
    margin-bottom: 8px;
}

.alert-icon {
    font-size: 20px;
    margin-right: 10px;
}

.alert-text {
    color: #856404;
    font-size: 14px;
}

.view-details-link {
    display: inline-block;
    margin-top: 10px;
    color: #0073aa;
    text-decoration: underline;
}
.view-details-link:hover {
    color: #005177;
}

.weather-weekly-container {
    display: block;
    visibility: visible;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
    max-width: 100%;
    background: #fff;
    padding: 16px;
}

.weather-weekly-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    margin-top: 16px;
}

.weather-day-card {
    display: flex;
    flex-direction: column;
    background: #fff;
    padding: 12px;
}

.weather-weekly-table {
    width: 100%;
    overflow-x: auto;
    margin: 16px 0;
}

.weather-weekly-table table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
}

.weather-weekly-table th,
.weather-weekly-table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #e9ecef;
    vertical-align: top;
}

.weather-weekly-table th {
    background: #f8f9fa;
    color: #2c3e50;
    font-weight: 500;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.weather-weekly-table tr:last-child td {
    border-bottom: none;
}

.weather-weekly-table .day-info {
    min-width: 100px;
}

.weather-weekly-table .day-name {
    font-size: 15px;
    font-weight: 500;
    color: #2c3e50;
    margin-bottom: 3px;
}

.weather-weekly-table .day-date {
    font-size: 13px;
    color: #6c757d;
}

.weather-weekly-table .day-conditions {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    min-width: 120px;
    padding: 4px;
}

.weather-weekly-table .weather-icon {
    width: 44px;
    height: 44px;
    margin-bottom: 6px;
}

.weather-weekly-table .condition-text {
    font-size: 13px;
    color: #2c3e50;
    line-height: 1.3;
}

.weather-weekly-table .day-temp {
    min-width: 120px;
}

.weather-weekly-table .temp-high {
    font-weight: 500;
    color: #e74c3c;
    margin-bottom: 3px;
}

.weather-weekly-table .temp-low {
    color: #3498db;
}

.weather-weekly-table .day-details {
    min-width: 250px;
}

.weather-weekly-table .detailed-forecast {
    font-size: 13px;
    line-height: 1.4;
    color: #2c3e50;
}

.weather-weekly-table .wind-info {
    margin-top: 6px;
    font-size: 12px;
    color: #6c757d;
}

.weather-hourly-container {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
    max-width: 100%;
    background: #fff;
    padding: 16px;
}

.weather-hourly-header {
    text-align: center;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid #eee;
}

.weather-hourly-title {
    font-size: 20px;
    font-weight: 500;
    color: #2c3e50;
    margin: 0 0 4px 0;
}

.weather-hourly-timestamp {
    font-size: 13px;
    color: #7f8c8d;
}

.weather-hourly-table {
    width: 100%;
    border-collapse: collapse;
    margin: 16px 0;
}

.weather-hourly-table th {
    background: #f8f9fa;
    padding: 10px;
    text-align: left;
    font-weight: 500;
    color: #2c3e50;
    border-bottom: 1px solid #dee2e6;
    font-size: 13px;
}

.weather-hourly-table td {
    padding: 10px;
    border-bottom: 1px solid #eee;
    vertical-align: middle;
    font-size: 13px;
}

.weather-hourly-table .hour-cell {
    font-weight: 500;
    color: #2c3e50;
    width: 100px;
}

.weather-hourly-table .temp-cell {
    font-size: 14px;
    font-weight: 400;
    color: #2c3e50;
    width: 100px;
}

.weather-hourly-table .icon-cell {
    width: 40px;
}

.weather-hourly-table .icon-cell img {
    width: 32px;
    height: 32px;
    display: block;
}

.weather-hourly-table .precip-cell {
    color: #3498db;
    width: 120px;
}

.weather-extended-container {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
    max-width: 900px;
    margin: 0 auto;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    padding: 5px 20px 20px 20px;
}

.weather-extended-header {
    text-align: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

.weather-extended-header .location-name {
    font-size: 1.8em;
    margin: 0 0 10px;
    color: #2c3e50;
}

.weather-extended-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 20px;
}

.weather-column {
    background: #f8f9fa;
    border-radius: 6px;
    padding: 15px;
}

.weather-column h3 {
    color: #2c3e50;
    font-size: 1.2em;
    margin: 0 0 15px;
    padding-bottom: 8px;
    border-bottom: 2px solid #e9ecef;
}

.primary-conditions {
    text-align: center;
}

.weather-icon-large img {
    width: 100px;
    height: 100px;
}

.current-temp-large .temp-main {
    font-size: 3em;
    font-weight: 500;
    color: #2c3e50;
    line-height: 1;
}

.weather-description {
    font-size: 1.2em;
    color: #34495e;
    margin: 10px 0;
}

.feels-like {
    font-size: 1.1em;
    color: #7f8c8d;
    margin-top: 10px;
}

.weather-detail {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 4px 0;
    border-bottom: 1px solid #e9ecef;
}

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

.detail-label {
    color: #6c757d;
}

.detail-value {
    font-weight: 500;
    color: #2c3e50;
}

.temp-high {
    color: #e74c3c;
}

.temp-low {
    color: #3498db;
}

.weather-extended-footer {
    margin-top: 20px;
    padding-top: 15px;
    border-top: 1px solid #eee;
    font-size: 0.9em;
    color: #6c757d;
}

.daylight-conditions {
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
}

.daylight-conditions .weather-detail {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

.daylight-conditions .weather-detail:last-child {
    border-bottom: none;
}

.daylight-conditions .detail-label {
    color: #2c3e50;
    font-weight: 500;
}

.daylight-conditions .sunrise-time,
.daylight-conditions .sunset-time {
    color: #f39c12;
    font-weight: 500;
}

.daylight-conditions .day-length {
    color: #2c3e50;
    font-weight: 500;
}

/* Hourly Forecast Styles */
.weather-hourly-container {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.weather-hourly-header {
    text-align: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

.weather-hourly-title {
    font-size: 1.2em;
    font-weight: 600;
    color: #2c3e50;
    margin: 0 0 5px;
}

.weather-hourly-timestamp {
    font-size: 0.8em;
    color: #7f8c8d;
}

.weather-hourly-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 10px;
    margin-top: 10px;
}

.hourly-forecast-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 6px;
    background: #f8f9fa;
    border-radius: 6px;
    transition: transform 0.2s;
}

.hourly-forecast-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.hour-cell {
    font-size: 0.9em;
    font-weight: 600;
    color: #2c3e50;
}

.temp-cell {
    font-size: 1.1em;
    font-weight: 500;
    color: #2c3e50;
}

.icon-cell img {
    width: 36px;
    height: 36px;
}

.precip-cell {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
}

.precip-label {
    font-size: 0.7em;
    color: #7f8c8d;
}

.precip-value {
    font-size: 0.9em;
    color: #3498db;
    font-weight: 500;
}

/* Weekly Forecast Styles */
.weather-weekly-container {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.weather-weekly-header {
    text-align: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

.weather-weekly-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
}

.weather-day-card {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 15px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    transition: transform 0.2s;
}

.weather-day-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.day-info {
    text-align: center;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
}

.day-name {
    font-size: 1.1em;
    font-weight: 600;
    color: #2c3e50;
}

.day-date {
    font-size: 0.8em;
    color: #7f8c8d;
    margin-top: 2px;
}

.day-conditions {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.day-conditions img {
    width: 48px;
    height: 48px;
}

.condition-text {
    text-align: center;
    font-size: 0.9em;
    color: #34495e;
}

.day-temp {
    display: flex;
    justify-content: center;
    gap: 20px;
}

.temp-high, .temp-low {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
}

.temp-label {
    font-size: 0.8em;
    color: #7f8c8d;
}

.temp-high .temp-value {
    color: #e74c3c;
    font-weight: 500;
}

.temp-low .temp-value {
    color: #3498db;
    font-weight: 500;
}

.day-details {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid #eee;
}

.wind-info, .night-forecast {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.9em;
}

.wind-label, .night-label {
    color: #7f8c8d;
}

.wind-value, .night-value {
    color: #2c3e50;
}

.detailed-forecast {
    font-size: 0.85em;
    color: #34495e;
    line-height: 1.4;
}

.detailed-forecast p {
    margin: 0;
}

@media (max-width: 768px) {
    .weather-hourly-container,
    .weather-weekly-container {
        padding: 12px;
    }

    .weather-hourly-title {
        font-size: 18px;
    }

    .weather-hourly-table td,
    .weather-hourly-table th {
        padding: 8px;
    }

    .weather-hourly-table .hour-cell {
        width: auto;
    }

    .weather-hourly-table .temp-cell {
        font-size: 13px;
    }

    .weather-weekly-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .weather-weekly-table td,
    .weather-weekly-table th {
        padding: 10px;
    }

    .weather-extended-container {
        padding: 5px 15px 15px 15px;
        margin: 0 10px;
    }
    
    .weather-extended-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
}

@media (max-width: 480px) {
    .weather-hourly-table {
        font-size: 13px;
    }
    
    .weather-hourly-table .icon-cell {
        display: none;
    }

    .weather-current-container {
        padding: 8px;
        min-height: auto;
    }

    .weather-content-wrapper {
        flex-direction: column;
        gap: 10px;
    }

    .weather-current-primary {
        display: grid;
        grid-template-columns: auto 1fr;
        grid-template-rows: auto auto auto;
        align-items: center;
        padding-right: 0;
        border-right: none;
        border-bottom: 1px solid #eee;
        padding-bottom: 10px;
        gap: 6px 12px;
    }

    .location-name {
        grid-column: 1 / -1;
        text-align: left;
        border-bottom: none;
        padding-bottom: 0;
    }

    .weather-icon-wrapper {
        grid-row: 2;
        padding: 0;
    }

    .weather-current-temp {
        grid-row: 2;
        text-align: left;
    }

    .weather-timestamp {
        display: none;
    }

    .weather-current-details {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 10px 6px;
        padding: 4px 0;
    }
}

@media print {
    .weather-weekly-container {
        border: 1px solid #000;
    }

    .weather-day-card {
        break-inside: avoid;
        border: 1px solid #ccc;
    }

    .toggle-details {
        display: none;
    }

    .detailed-forecast {
        display: block !important;
    }
}

/* Weather Alert Styles */
.weather-alerts-banner {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
    margin: 0;
    padding: 0;
}

.weather-alert-item {
    background: #fff;
    margin-bottom: 8px;
    border-radius: 4px;
    overflow: hidden;
}

.weather-alert-item:last-child {
    margin-bottom: 0;
}

.alert-content {
    padding: 8px;
}

.alert-header {
    background: #ff9800;
    margin: -8px -8px 8px -8px;
    padding: 6px 8px;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.alert-event {
    font-size: 1em;
    font-weight: 500;
    color: #fff;
}

.alert-severity,
.alert-expires {
    font-size: 0.85em;
    color: rgba(255, 255, 255, 0.9);
}

.alert-details {
    background: #fff;
    padding: 0;
}

.alert-timing {
    margin-bottom: 8px;
}

.alert-full-description {
    font-size: 0.85em;
    line-height: 1.4;
    margin-bottom: 8px;
    color: #2c3e50;
}

.alert-instructions {
    background: rgba(0, 0, 0, 0.03);
    padding: 8px;
    border-radius: 4px;
    margin-top: 8px;
}

.alert-description {
    font-size: 0.85em;
    line-height: 1.4;
    color: #2c3e50;
}

.alert-details-link {
    margin-top: 4px;
    text-align: right;
}

.view-details-link {
    font-size: 0.8em;
    color: #2c3e50;
    text-decoration: none;
}

.view-details-link:hover {
    text-decoration: underline;
}

/* Alert Severity Colors */
.alert-extreme .alert-header {
    background: #c0392b;
}

.alert-severe .alert-header {
    background: #e74c3c;
}

.alert-moderate .alert-header {
    background: #ff9800;
}

.alert-minor .alert-header {
    background: #f39c12;
}