/* ============================================================ */
/* ===== ESTILOS PRINCIPALES ===== */
/* ============================================================ */

* {
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

::selection {
    background: #0af;
    color: #000;
}

html,
body {
    margin: 0;
    padding: 0;
    overflow-x: hidden;
    width: 100%;
}

body {
    background: #0a0c10;
    color: #e0e0e0;
    font-family: 'Segoe UI', 'Courier New', monospace;
    margin: 0;
    padding: 15px;
    font-size: 14.4px;
    line-height: 1.5;
    overflow-x: hidden !important;
    width: 100% !important;
    box-sizing: border-box !important;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    width: 100% !important;
    max-width: 100% !important;
    padding: 0 10px !important;
    box-sizing: border-box !important;
    overflow-x: hidden !important;
}


/* ============================================================ */
/* ===== HEADER ===== */
/* ============================================================ */

.header-container {
    text-align: center;
    padding: 20px 0 15px;
    margin: 0 0 15px;
    position: relative;
    overflow: hidden;
    background: linear-gradient(180deg, rgba(0, 170, 255, 0.3) 0, transparent 100%);
}

.header-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: repeating-linear-gradient(0deg, transparent, transparent 2px, rgba(0, 0, 0, 0.02) 2px, rgba(0, 0, 0, 0.02) 4px);
    pointer-events: none;
    z-index: 1;
}

.header-text {
    position: relative;
    z-index: 2;
}

.header-title {
    font-size: 2.16em;
    font-weight: 600;
    color: #0af;
    letter-spacing: 3px;
    margin: 0;
    line-height: 1.2;
    text-shadow: 0 0 15px rgba(0, 170, 255, 0.3);
}

.header-callsign {
    font-size: 1.62em;
    font-weight: 600;
    color: #e0e0e0;
    letter-spacing: 8px;
    margin: 8px 0 0;
    text-shadow: 0 0 10px rgba(0, 170, 255, 0.3);
    display: inline-block;
    position: relative;
}

.header-callsign::before {
    content: '◄ ';
    color: #0af;
    font-size: 0.7em;
}

.header-callsign::after {
    content: ' ►';
    color: #0af;
    font-size: 0.7em;
}

.header-status {
    position: absolute;
    top: 15px;
    right: 20px;
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 10.8px;
    color: #0af;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.header-home-link {
    color: #0af;
    text-decoration: none;
    font-size: 18px;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.header-home-link:hover {
    transform: scale(1.1);
    text-shadow: 0 0 8px #0af;
}

.header-status-dot {
    width: 8px;
    height: 8px;
    background: #0af;
    border-radius: 50%;
    box-shadow: 0 0 8px #0af;
    animation: statusBlink 1.5s ease-in-out infinite;
}

@keyframes statusBlink {
    0%,
    100% {
        opacity: 1;
    }
    50% {
        opacity: 0.3;
    }
}

.paypal-header-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #ffaa00;
    color: #0a0c10;
    padding: 5px 12px;
    border-radius: 30px;
    font-weight: 600;
    font-size: 11px;
    text-decoration: none;
    font-family: monospace;
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
    margin-left: 5px;
}

.paypal-header-btn:hover {
    background: #ffcc44;
    transform: scale(1.02);
}

.paypal-header-btn span {
    font-size: 12px;
}


/* ============================================================ */
/* ===== BOTONES PRINCIPALES ===== */
/* ============================================================ */

.btn-principal {
    display: inline-block;
    margin: 0;
    padding: 8px 22px;
    background: transparent;
    border: 2px solid #0af;
    color: #0af;
    text-decoration: none;
    font-size: 0.91em;
    font-weight: 700;
    border-radius: 8px;
    transition: all 0.3s ease;
    min-height: 36px;
    cursor: pointer;
    letter-spacing: 1px;
}

.btn-principal:hover {
    background: #0af;
    color: #0a0c10;
    transform: translateY(-2px);
    box-shadow: 0 0 15px rgba(0, 170, 255, 0.3);
}

.btn-wrapper {
    text-align: center;
    display: flex;
    gap: 15px;
    justify-content: flex-end;
    align-items: center;
    margin-bottom: 10px;
}


/* ============================================================ */
/* ===== LOCATOR SEARCH ===== */
/* ============================================================ */

.locator-search {
    background: #0f1218;
    border: 1px solid #1a3a5a;
    padding: 12px 15px;
    margin: 12px auto;
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    max-width: 1400px;
    width: 100%;
}

.locator-search label {
    margin: 0;
    font-size: 13px;
    font-weight: 600;
    color: #ffffff;
    text-align: center;
}

.locator-search .locator-input-wrapper {
    display: flex;
    gap: 8px;
    align-items: center;
    justify-content: center;
    flex-wrap: nowrap;
    width: 100%;
}

.locator-search input {
    background: #0a0c10;
    border: 1px solid #1a3a5a;
    color: #ffaa00;
    padding: 8px 8px;
    font-size: 12px;
    text-align: center;
    text-transform: uppercase;
    border-radius: 8px;
    transition: all 0.3s;
    width: 100px;
    flex: 2;
}

.locator-search input:focus {
    outline: none;
    border-color: #0af;
    box-shadow: 0 0 8px rgba(0, 170, 255, 0.3);
}

.locator-search .buttons-group {
    display: flex;
    gap: 6px;
    align-items: center;
    justify-content: center;
    flex: 3;
}

.locator-search button {
    background: transparent;
    border: 1px solid #0af;
    color: #0af;
    padding: 8px 12px;
    cursor: pointer;
    border-radius: 8px;
    font-size: 12px;
    transition: all 0.3s;
    white-space: nowrap;
    font-weight: 600;
}

.locator-search button#btn-default {
    font-size: 0;
}

.locator-search button#btn-default::before {
    content: "Mi ubicación";
    font-size: 12px;
}

.locator-search button:hover,
.locator-search button.active {
    background: #0af;
    color: #0a0c10;
}

.locator-info {
    font-size: 11px;
    color: #0af;
    margin: 0;
    text-align: center;
    font-weight: 500;
    word-break: break-word;
}

.locator-error {
    color: #f66;
    font-size: 13px;
    margin: 0;
    text-align: center;
}


/* ============================================================ */
/* ===== WEATHER WIDGET ===== */
/* ============================================================ */

.weather-widget {
    background: #0f1218;
    border: 1px solid #1a3a5a;
    border-radius: 8px;
    padding: 12px 15px;
    margin: 12px auto;
    max-width: 1400px;
    width: 100%;
    font-size: 13px;
    transition: all 0.3s ease;
    text-align: center;
}

.weather-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    border-bottom: 1px solid #1a3a5a;
    padding-bottom: 5px;
    margin-bottom: 10px;
    font-size: 12px;
    color: #888;
}

.weather-location {
    font-weight: 600;
    color: #ffffff;
    font-size: 14px;
}

.weather-main {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.weather-icon {
    font-size: 40px;
    text-align: center;
    min-width: auto;
}

.weather-temp {
    font-size: 28px;
    font-weight: bold;
    color: #0af;
    min-width: auto;
    text-align: center;
    transition: color 0.5s ease, text-shadow 0.5s ease;
}

.weather-left {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.weather-details {
    display: flex;
    flex-direction: row;
    gap: 20px;
    background: rgba(0, 0, 0, 0.15);
    padding: 6px 15px;
    border-radius: 8px;
    flex-wrap: wrap;
    justify-content: center;
}

.weather-details div {
    white-space: nowrap;
    font-size: 11px;
    color: #e0e0e0;
}

.weather-desc {
    margin-top: 8px;
    font-size: 11px;
    color: #888;
    text-align: center;
    font-style: italic;
    display: none;
}


/* ============================================================ */
/* ===== STATUS ===== */
/* ============================================================ */

.status {
    text-align: center;
    margin: 8px 0;
    font-size: 14.4px;
    color: #0af;
}


/* ============================================================ */
/* ===== SELECTOR DE SATÉLITES ===== */
/* ============================================================ */

details#selector {
    background: #0f1218;
    border: 1px solid #1a3a5a;
    padding: 13px;
    margin: 12px 0;
    border-radius: 8px;
}

details#selector summary {
    cursor: pointer;
    font-weight: 600;
    list-style: none;
    font-size: 15.3px;
    padding-bottom: 8px;
    border-bottom: 1px solid #1a3a5a;
    margin-bottom: 10px;
    min-height: 22px;
    color: #ffffff;
}

details#selector summary::-webkit-details-marker {
    display: none;
}

details#selector summary::before {
    content: "▶ ";
    color: #0af;
}

details[open] summary::before {
    content: "▼ ";
}

#typewriter-text {
    border-right: 2px solid #0af;
    padding-right: 4px;
    animation: blinkCursor 0.8s step-end infinite;
}

@keyframes blinkCursor {
    50% {
        border-color: transparent;
    }
}

.sel-controls {
    display: flex;
    gap: 10px;
    margin: 10px 0;
    flex-wrap: wrap;
}

.sel-controls input {
    background: #0a0c10;
    border: 1px solid #1a3a5a;
    color: #e0e0e0;
    padding: 7px 11px;
    flex: 1;
    min-width: 160px;
    font-size: 14.4px;
    border-radius: 6px;
}

.sel-controls button {
    background: transparent;
    border: 1px solid #0af;
    color: #0af;
    padding: 7px 12px;
    cursor: pointer;
    border-radius: 6px;
    font-size: 14.4px;
    transition: all 0.3s;
    min-height: 40px;
}

.sel-controls button:hover {
    background: #0af;
    color: #0a0c10;
}

.mode-filters {
    display: flex;
    gap: 8px;
    margin: 10px 0;
    flex-wrap: wrap;
    justify-content: center;
}

.mode-filter-btn {
    padding: 4px 11px;
    border-radius: 20px;
    font-size: 0.68rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    border: 1px solid transparent;
    background: rgba(150, 150, 150, 0.15);
    color: #888;
}

.mode-filter-btn:hover {
    transform: translateY(-1px);
    opacity: 0.8;
}

.mode-filter-btn.active {
    background: rgba(0, 170, 255, 0.2);
    border-color: #0af;
    color: #0af;
}

.mode-filter-btn.fm {
    background: rgba(255, 221, 0, 0.15);
    border-color: #ffdd00;
    color: #ffdd00;
}

.mode-filter-btn.ssb {
    background: rgba(0, 255, 0, 0.15);
    border-color: #0f0;
    color: #0f0;
}

.mode-filter-btn.cw {
    background: rgba(0, 204, 255, 0.15);
    border-color: #0cf;
    color: #0cf;
}

.mode-filter-btn.sstv {
    background: rgba(255, 100, 0, 0.15);
    border-color: #f60;
    color: #f60;
}

.mode-filter-btn.aprs {
    background: rgba(204, 0, 255, 0.15);
    border-color: #c0f;
    color: #c0f;
}

.sel-list {
    max-height: 350px;
    overflow-y: auto;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 6px;
    padding-right: 5px;
}

.sat-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 7px 9px;
    border-radius: 6px;
    border: 1px solid transparent;
    transition: all 0.2s;
}

.sat-item:hover {
    background: rgba(0, 170, 255, 0.05);
    border-color: #1a3a5a;
}

.sat-item input {
    margin: 0;
    width: 18px;
    height: 18px;
    accent-color: #0af;
}

.sat-item label {
    cursor: pointer;
    font-size: 14.4px;
    color: #e0e0e0;
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.sel-actions {
    margin-top: 12px;
    display: flex;
    gap: 10px;
}

.sel-actions button {
    background: #0af;
    color: #0a0c10;
    border: none;
    padding: 9px 18px;
    cursor: pointer;
    font-weight: 600;
    border-radius: 6px;
    font-size: 14.4px;
    transition: all 0.3s;
    min-height: 40px;
}

.sel-actions button:hover {
    opacity: 0.8;
}

.sel-actions button.secondary {
    background: transparent;
    color: #0af;
    border: 1px solid #0af;
}

.sel-info {
    margin-top: 10px;
    font-size: 14.4px;
    color: #888;
}


/* ============================================================ */
/* ===== TABLA ===== */
/* ============================================================ */

.table-wrapper {
    overflow-x: auto;
    margin-top: 15px;
    display: none;
    border-radius: 8px;
    -webkit-overflow-scrolling: touch;
    width: 100% !important;
    max-width: 100% !important;
}

.table-wrapper.visible {
    display: block;
}

table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    border: 2px solid #1a3a5a;
    background: transparent;
    font-size: 14.4px;
    border-radius: 8px;
    overflow: hidden;
    min-width: auto !important;
}

th,
td {
    border: 1px solid #1a3a5a;
    padding: 7px 11px;
    text-align: center;
    white-space: nowrap;
    vertical-align: middle;
}

th {
    background: #0f1218;
    position: sticky;
    top: 0;
    font-weight: 600;
    font-size: 15.3px;
    color: #0af;
    z-index: 10;
}

tr:hover {
    background: rgba(0, 170, 255, 0.05);
}

tr.detail-row {
    display: none;
    background: #0a0c10;
}

tr.detail-row.visible {
    display: table-row;
}

tr.detail-row td {
    padding: 13px !important;
    border: none !important;
}

.hide-details-btn {
    background: linear-gradient(135deg, rgba(0, 170, 255, 0.15) 0%, rgba(0, 170, 255, 0.05) 100%);
    border: 1px solid #0af;
    color: #0af;
    padding: 7px 14px;
    cursor: pointer;
    border-radius: 6px;
    font-size: 12.6px;
    font-weight: 600;
    transition: all 0.3s;
    min-height: 36px;
    margin-top: 12px;
    width: 100%;
    text-align: center;
}

.hide-details-btn:hover {
    background: linear-gradient(135deg, rgba(0, 170, 255, 0.25) 0%, rgba(0, 170, 255, 0.1) 100%);
    color: #e0e0e0;
}

.notify-btn {
    background: rgba(255, 170, 0, 0.15);
    border: 1px solid #ffaa00;
    color: #ffaa00;
    padding: 4px 9px;
    border-radius: 20px;
    font-size: 0.63rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.notify-btn:hover {
    background: #ffaa00;
    color: #0a0c10;
}

.status-cell {
    font-weight: 600;
    text-align: center;
}

.status-cell.vis {
    color: #2ecc71;
    text-shadow: 0 0 4px rgba(46, 204, 113, 0.5);
}

.status-cell.warning {
    color: #ffaa00;
    text-shadow: 0 0 4px rgba(255, 170, 0, 0.5);
}

.status-cell.hid {
    color: #ff0000;
    text-shadow: 0 0 4px rgba(255, 0, 0, 0.5);
}

.norad-bracket {
    color: #888;
    margin: 0 2px;
}

.max-el-display {
    color: #ffaa00;
    font-weight: 600;
    margin-left: 12px;
    white-space: nowrap;
}


/* ============================================================ */
/* ===== TARJETAS (MÓVIL) ===== */
/* ============================================================ */

.sat-card {
    display: none;
    background: #0f1218;
    border: 1px solid #1a3a5a;
    border-radius: 12px;
    padding: 0;
    margin: 12px 0;
    overflow: hidden;
    transition: all 0.3s ease;
    font-family: 'Poppins', 'Arial', 'Helvetica', sans-serif;
    max-width: 100% !important;
}

.sat-card.visible {
    display: block;
}

.sat-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 18px;
    border-bottom: 1px solid #1a3a5a;
    gap: 12px;
    flex-wrap: wrap;
    transition: all 0.3s ease;
}

.sat-card-header.visible-bg {
    background: linear-gradient(135deg, rgba(46, 204, 113, 0.25) 0%, rgba(46, 204, 113, 0.08) 100%);
    border-left: 4px solid #2ecc71;
    box-shadow: 0 0 15px rgba(46, 204, 113, 0.2);
}

.sat-card-header.warning-bg {
    background: linear-gradient(135deg, rgba(255, 170, 0, 0.2) 0%, rgba(255, 170, 0, 0.05) 100%);
    border-left: 4px solid #ffaa00;
}

.sat-card-header.hid-bg {
    background: linear-gradient(135deg, rgba(0, 170, 255, 0.15) 0%, rgba(0, 170, 255, 0.05) 100%);
    border-left: 4px solid #0af;
}

.sat-card-name {
    font-size: 1em;
    font-weight: 600;
    color: #0af;
    letter-spacing: 0.5px;
    flex: 1;
    min-width: 0;
}

.sat-card-header.visible-bg .sat-card-name {
    color: #2ecc71;
}

.sat-card-header.warning-bg .sat-card-name {
    color: #ffaa00;
}

.sat-card-header.hid-bg .sat-card-name {
    color: #ffffff;
}

.sat-card-maxel {
    color: #ffaa00;
    font-size: 1em;
    font-weight: 600;
    margin-left: 10px;
    white-space: nowrap;
}

.sat-card-maxel-label {
    color: #ffaa00;
    font-size: 1em;
    font-weight: 500;
    margin-right: 4px;
}

.sat-card-maxel-value {
    font-size: 1em;
    font-weight: 700;
}

.sat-card-status {
    font-size: 0.63rem;
    padding: 3px 11px;
    border-radius: 20px;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    display: flex;
    align-items: center;
    gap: 5px;
    white-space: nowrap;
    flex-shrink: 0;
}

.sat-card-status::before {
    content: '';
    width: 6px;
    height: 6px;
    border-radius: 50%;
    display: inline-block;
    animation: pulseDot 1.5s infinite;
}

.sat-card-status.vis {
    background: rgba(46, 204, 113, 0.2);
    color: #2ecc71;
    border: 1px solid rgba(46, 204, 113, 0.5);
}

.sat-card-status.vis::before {
    background: #2ecc71;
    box-shadow: 0 0 5px #2ecc71;
}

.sat-card-status.warning {
    background: rgba(255, 170, 0, 0.2);
    color: #ffaa00;
    border: 1px solid rgba(255, 170, 0, 0.5);
}

.sat-card-status.warning::before {
    background: #ffaa00;
    box-shadow: 0 0 5px #ffaa00;
}

.sat-card-status.hid {
    background: rgba(255, 0, 0, 0.15);
    color: #ff0000;
    border: 1px solid rgba(255, 0, 0, 0.3);
}

.sat-card-status.hid::before {
    background: #ff0000;
    box-shadow: 0 0 5px #ff0000;
}

@keyframes pulseDot {
    0%,
    100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.6;
        transform: scale(1.2);
    }
}

.sat-card-subinfo {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 7px 18px;
    background: rgba(0, 0, 0, 0.05);
    border-bottom: 1px solid #1a3a5a;
    font-size: 0.68rem;
    flex-wrap: wrap;
    gap: 8px;
}

.sat-card-mode {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 4px 12px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.75rem;
    letter-spacing: 0.5px;
}

.sat-card-mode.fm {
    background: rgba(255, 221, 0, 0.2);
    border: 1px solid #ffdd00;
    color: #ffdd00;
}

.sat-card-mode.ssb {
    background: rgba(0, 255, 0, 0.15);
    border: 1px solid #0f0;
    color: #0f0;
}

.sat-card-mode.cw {
    background: rgba(0, 204, 255, 0.15);
    border: 1px solid #0cf;
    color: #0cf;
}

.sat-card-mode.sstv {
    background: rgba(255, 100, 0, 0.15);
    border: 1px solid #f60;
    color: #f60;
}

.sat-card-mode.aprs {
    background: rgba(204, 0, 255, 0.15);
    border: 1px solid #c0f;
    color: #c0f;
}

.sat-card-mode.default {
    background: rgba(150, 150, 150, 0.15);
    border: 1px solid #888;
    color: #888;
}

.sat-card-gcal-btn {
    background: rgba(255, 170, 0, 0.15);
    border: 1px solid #ffaa00;
    color: #ffaa00;
    padding: 3px 11px;
    border-radius: 20px;
    font-size: 0.63rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 5px;
}

.sat-card-gcal-btn:hover {
    background: #ffaa00;
    color: #0a0c10;
}

.sat-info-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
    margin-bottom: 13px;
    background: rgba(0, 0, 0, 0.03);
    border-radius: 8px;
    padding: 11px;
}

.sat-info-item {
    background: #0a0c10;
    padding: 9px 11px;
    border-radius: 6px;
    transition: all 0.2s;
}

.sat-info-item:hover {
    background: rgba(0, 170, 255, 0.05);
}

.sat-info-label {
    font-size: 9px;
    color: #0af;
    display: block;
    margin-bottom: 4px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.sat-info-value {
    font-size: 14.4px;
    font-weight: 600;
    color: #e0e0e0;
}

.sat-card-details-btn {
    background: linear-gradient(135deg, rgba(0, 170, 255, 0.15) 0%, rgba(0, 170, 255, 0.05) 100%);
    color: #0af;
    border: 1px solid #0af;
    border-top: 1px solid #1a3a5a;
    padding: 11px 18px;
    cursor: pointer;
    font-weight: 600;
    border-radius: 0;
    font-size: 12.6px;
    transition: all 0.3s;
    width: 100%;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    min-height: 40px;
}

.sat-card-details-btn:hover {
    background: linear-gradient(135deg, rgba(0, 170, 255, 0.25) 0%, rgba(0, 170, 255, 0.1) 100%);
    color: #e0e0e0;
}

.sat-card-detail-panel {
    display: none;
    border-top: 1px solid #1a3a5a;
    background: rgba(0, 0, 0, 0.02);
}

.sat-card-detail-panel.visible {
    display: block;
}


/* ============================================================ */
/* ===== DETALLE CONTENT (RADAR + MAPA) ===== */
/* ============================================================ */

.detail-content {
    padding: 13px;
    display: grid;
    grid-template-columns: 2fr 3fr;
    gap: 20px;
    align-items: stretch;
    max-width: 100% !important;
    overflow: hidden !important;
}

.map-container,
.radar-wrapper {
    border: 1px solid #1a3a5a;
    border-radius: 8px;
    overflow: hidden;
    background: #0a0c10;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    height: 100%;
    max-width: 100% !important;
}

.radar-wrapper {
    background: transparent;
    padding: 11px;
    text-align: center;
    overflow: hidden !important;
}

.radar-flex {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 15px !important;
}

.radar-container {
    display: inline-block !important;
    flex: 0 1 auto !important;
    min-width: 0 !important;
    transform-origin: center center;
    cursor: pointer;
}

.radar-canvas {
    max-width: 100% !important;
    height: auto !important;
    display: block !important;
    margin: 0 auto !important;
    will-change: transform;
}

.elev-bar {
    display: inline-block !important;
    flex: 0 0 auto !important;
    width: 14px !important;
    height: 220px !important;
    background: linear-gradient(to top, rgba(0, 170, 255, 0.1), rgba(0, 170, 255, 0.3)) !important;
    border: 1px solid #1a3a5a !important;
    border-radius: 8px !important;
    position: relative !important;
    padding: 3px 0 !important;
}

.elev-marker {
    position: absolute;
    right: -7px;
    width: 10px;
    height: 10px;
    background: #f66;
    clip-path: polygon(100% 50%, 0% 0%, 0% 100%);
    transform: translateY(-50%);
    transition: top 0.3s ease-out;
}

.elev-ticks {
    position: absolute;
    right: -32px;
    top: 0;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.elev-ticks span {
    font-size: 9px;
    color: #888;
}

.time-info {
    text-align: center;
    margin: 10px auto;
    padding: 8px 20px;
    background: rgba(0, 0, 0, 0.4);
    border-radius: 10px;
    display: inline-block;
    width: auto;
    font-size: 18px;
    font-weight: 600;
    color: #0af;
    text-shadow: 0 0 10px rgba(0, 170, 255, 0.3);
    font-family: monospace;
}

.time-info .utc {
    color: #ffaa00;
    font-size: 20px;
    font-weight: 600;
}

.radar-cor-freq {
    display: flex;
    justify-content: center;
    gap: 40px;
    margin: 10px 0 8px 0;
    font-size: 16px;
    flex-wrap: wrap;
}

.radar-cor-freq .rx-cor {
    color: #44ff44 !important;
    font-weight: 700;
    font-size: 18px;
}

.radar-cor-freq .rx-cor strong {
    color: #66ff66 !important;
    font-weight: bold;
}

.radar-cor-freq .tx-cor {
    color: #44ff44 !important;
    font-weight: 700;
    font-size: 18px;
}

.radar-cor-freq .tx-cor strong {
    color: #66ff66 !important;
    font-weight: bold;
}

.spectrum-container {
    width: 100%;
    margin-top: 5px;
    padding: 0 10px;
}

.spectrum-canvas {
    width: 100%;
    height: 120px;
    background: transparent;
    display: block;
}

.button-group {
    display: flex;
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 12px;
}

.btn-radar {
    background: transparent;
    border: 2px solid #0af;
    color: #0af;
    padding: 5px 12px;
    font-size: 12px;
    cursor: pointer;
    border-radius: 6px;
    transition: all 0.3s;
    min-height: 36px;
    box-shadow: 0 0 8px rgba(0, 170, 255, 0.3);
}

.btn-radar:hover {
    box-shadow: 0 0 15px rgba(0, 170, 255, 0.3);
    background: rgba(0, 170, 255, 0.1);
}

.btn-radar.compass.active {
    background: #0af;
    color: #0a0c10;
    box-shadow: 0 0 20px rgba(0, 170, 255, 0.3);
}

.btn-radar.mic-control {
    background: transparent;
    border-color: #ffaa00;
    color: #ffaa00;
    box-shadow: 0 0 8px rgba(255, 170, 0, 0.5);
}

.btn-radar.mic-control.active {
    background: #ffaa00;
    color: #0a0c10;
    box-shadow: 0 0 20px rgba(255, 170, 0, 0.8);
}

.btn-radar.record-control {
    background: transparent;
    border-color: #ff4444;
    color: #ff4444;
    box-shadow: 0 0 8px rgba(255, 68, 68, 0.5);
    min-width: 70px;
}

.btn-radar.record-control.recording {
    background: #ff4444;
    color: #fff;
    box-shadow: 0 0 20px rgba(255, 68, 68, 0.8);
    animation: recordPulse 1s infinite;
}

@keyframes recordPulse {
    0%,
    100% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
}

.btn-radar.calibrate {
    background: transparent;
    border-color: #888;
    color: #888;
    box-shadow: 0 0 4px rgba(136, 136, 136, 0.3);
}

.btn-radar.calibrate:hover {
    background: #0af;
    color: #0a0c10;
    border-color: #0af;
}

.btn-radar.calibrate.active {
    background: #44ff44;
    color: #0a0c10;
    border-color: #44ff44;
    box-shadow: 0 0 20px rgba(68, 255, 68, 0.6);
}

.recording-timer {
    font-size: 11px;
    color: #ff4444;
    margin-left: 8px;
    display: inline-block;
}


/* ============================================================ */
/* ===== DOPPLER ===== */
/* ============================================================ */

.doppler-panel {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 13px;
    margin-bottom: 16px;
}

.doppler-panel.single-card {
    grid-template-columns: 1fr;
    max-width: 500px;
    margin: 0 auto;
}

.doppler-panel.single-card .doppler-card.rx-card {
    border-left: 4px solid #ff4444;
}

.doppler-panel.single-card .doppler-card.rx-card h4 {
    color: #ff4444;
}

.doppler-card {
    padding: 13px;
    border-radius: 8px;
    border: 1px solid #1a3a5a;
    background: #0a0c10;
    transition: all 0.3s ease;
}

.doppler-card.tx-card {
    border-left: 4px solid #ffaa00;
}

.doppler-card.tx-card h4 {
    color: #ffaa00;
}

.doppler-card.rx-card {
    border-left: 4px solid #0af;
}

.doppler-card.rx-card h4 {
    color: #0af;
}

.doppler-card h4 {
    margin: 0 0 12px;
    padding-bottom: 7px;
    font-size: 15.3px;
    font-weight: 600;
}

.doppler-freq-line {
    font-size: 1.3em;
    margin: 10px 0;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-start;
    gap: 12px;
}

.doppler-freq-title {
    color: #fff;
    font-weight: 600;
    font-size: 1.2em;
}

.doppler-freq-value {
    color: #0f0;
    font-weight: 700;
    font-size: 1.2em;
}

.freq-neon-value {
    color: #0f0;
    font-weight: 700;
    text-shadow: none;
    font-size: 1.2em;
}

.doppler-ctss {
    color: #f66;
    font-weight: 600;
    display: inline-block;
    font-size: 1.1em;
    margin-left: 5px;
}

.doppler-correction {
    font-size: 1.1em;
    font-weight: 600;
    display: inline-block;
    margin-left: 15px;
    color: #ff4444;
}

.doppler-correction.tx {
    color: #ff4444;
}

.doppler-correction.rx {
    color: #ff4444;
}

.corrected-freq-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 8px;
    padding: 8px 15px;
    background: rgba(0, 0, 0, 0.3);
    font-size: 16px;
    border-bottom: 1px solid #1a3a5a;
}

.corrected-freq-header .rx-cor {
    color: #44ff44 !important;
    font-weight: 700;
}

.corrected-freq-header .rx-cor strong {
    color: #66ff66 !important;
    font-weight: bold;
}

.corrected-freq-header .tx-cor {
    color: #44ff44 !important;
    font-weight: 700;
}

.corrected-freq-header .tx-cor strong {
    color: #66ff66 !important;
    font-weight: bold;
}


/* ============================================================ */
/* ===== ELEMENTOS DE TABLA ===== */
/* ============================================================ */

.grid-click-info {
    margin-top: 11px;
    font-size: 14.4px;
    color: #888;
}

.aos {
    font-variant-numeric: tabular-nums;
}

.freq-cell small {
    display: block;
    line-height: 1.4;
}

.freq-note {
    color: #f66;
    font-size: 14.4px;
    font-weight: 600;
}

.mode-badge {
    padding: 3px 7px;
    border-radius: 6px;
    font-size: 14.4px;
    display: inline-block;
    min-width: 45px;
    font-weight: 600;
}

.mode-badge.fm {
    background: rgba(255, 221, 0, 0.15);
    border: 1px solid #ffdd00;
    color: #ffdd00;
}

.mode-badge.ssb {
    background: rgba(0, 255, 0, 0.15);
    border: 1px solid #0f0;
    color: #0f0;
}

.mode-badge.cw {
    background: rgba(0, 204, 255, 0.15);
    border: 1px solid #0cf;
    color: #0cf;
}

.mode-badge.sstv {
    background: rgba(255, 100, 0, 0.15);
    border: 1px solid #f60;
    color: #f60;
}

.mode-badge.aprs {
    background: rgba(204, 0, 255, 0.15);
    border: 1px solid #c0f;
    color: #c0f;
}

.mode-badge.default {
    background: rgba(150, 150, 150, 0.15);
    border: 1px solid #888;
    color: #888;
}

.freq-label {
    color: #ffaa00;
    font-weight: 600;
}

.freq-val {
    color: #0af;
}

.wait-message {
    text-align: center;
    padding: 22px;
    color: #888;
    font-size: 15.3px;
    border: 1px dashed #1a3a5a;
    border-radius: 8px;
    margin: 13px 0;
    background: rgba(0, 170, 255, 0.02);
}

.wait-message strong {
    color: #0af;
}

.satellite-name-cell {
    display: flex;
    align-items: center;
    gap: 12px;
    justify-content: space-between;
    width: 100%;
}

.sat-name-link {
    cursor: pointer;
    color: #0af;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 14.4px;
    transition: all 0.2s;
    white-space: nowrap;
}

.sat-name-link:hover {
    text-shadow: 0 0 8px #0af;
}

.sat-name-link.expanded .toggle-icon {
    transform: rotate(90deg);
}

.status-badge {
    font-size: 0.68rem;
    padding: 3px 9px;
    border-radius: 20px;
    font-weight: 600;
    white-space: nowrap;
}

.status-badge.vis {
    background: rgba(46, 204, 113, 0.15);
    color: #2ecc71;
}

.status-badge.warning {
    background: rgba(255, 170, 0, 0.15);
    color: #ffaa00;
}

.status-badge.hid {
    background: rgba(255, 0, 0, 0.15);
    color: #ff0000;
}

.map-container {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: 100%;
    max-width: 100% !important;
    overflow: hidden !important;
}

.map-container>div[class$="-map-div"] {
    width: 100% !important;
    height: 100% !important;
    border: none;
}


/* ============================================================ */
/* ===== LEYENDA DEL MAPA ===== */
/* ============================================================ */

.leaflet-control-legend {
    position: relative;
    background: #0f1218;
    border: 1px solid #1a3a5a;
    border-radius: 6px;
    overflow: hidden;
    z-index: 1000;
    width: auto;
    min-width: 130px;
    max-width: 180px;
}

.leaflet-control-legend .legend-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease-out;
}

.leaflet-control-legend .legend-content.open {
    max-height: 200px;
    overflow-y: auto;
}

.leaflet-control-legend .legend-content-inner {
    padding: 7px 11px;
}

.leaflet-control-legend .legend-content-inner div {
    margin: 5px 0;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 10px;
    color: #e0e0e0;
    white-space: nowrap;
}

.leaflet-control-legend .legend-color {
    width: 18px;
    height: 3px;
    display: inline-block;
    border-radius: 2px;
    flex-shrink: 0;
}

.legend-toggle-btn {
    background: rgba(0, 40, 60, 0.6);
    border: none;
    color: #0af;
    padding: 7px 12px;
    font-size: 11.7px;
    font-weight: 600;
    cursor: pointer;
    width: 100%;
    text-align: left;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    transition: all 0.3s;
}

.legend-toggle-btn:hover {
    background: rgba(0, 170, 255, 0.15);
    color: #e0e0e0;
}

.legend-toggle-btn .arrow {
    transition: transform 0.3s;
    font-size: 9px;
}

.legend-toggle-btn.open .arrow {
    transform: rotate(180deg);
}


/* ============================================================ */
/* ===== LOGBOOK ===== */
/* ============================================================ */

.logbook-section {
    margin-bottom: 15px;
    border: 1px solid #1a3a5a;
    border-radius: 10px;
    background: #0a0e1a;
}

.logbook-section-content {
    padding: 12px 15px;
}

.logbook-section-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 15px;
    background: #0f1218;
    cursor: pointer;
    border-radius: 10px 10px 0 0;
}

.logbook-section-header-left {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
}

.logbook-section-toggle {
    font-size: 1em;
    transition: transform 0.3s ease;
    color: #0af;
}

.logbook-section.collapsed .logbook-section-toggle {
    transform: rotate(-90deg);
}

.logbook-section.collapsed .logbook-section-content {
    display: none;
}

.logbook-section-icon {
    font-size: 1.2em;
}

.logbook-section-title {
    font-size: 1em;
    font-weight: 600;
    color: #0af;
    margin: 0;
}

.logbook-section-badge {
    background: rgba(0, 170, 255, 0.2);
    border: 1px solid #0af;
    color: #0af;
    padding: 2px 8px;
    border-radius: 20px;
    font-size: 0.7em;
}

.logbook-form-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    margin-bottom: 15px;
    width: 100%;
}

.logbook-form-group {
    width: 100%;
    display: flex;
    flex-direction: column;
}

.logbook-form-group label {
    font-size: 13px !important;
    font-weight: 600;
    color: #0af;
    margin-bottom: 6px;
    letter-spacing: 0.5px;
}

.logbook-input {
    background: #0a0c10;
    border: 1px solid #1a3a5a;
    color: #e0e0e0;
    padding: 10px 12px !important;
    border-radius: 6px;
    font-size: 14px !important;
    font-family: monospace;
    width: 100% !important;
    box-sizing: border-box;
}

.logbook-input:focus {
    outline: none;
    border-color: #0af;
    box-shadow: 0 0 8px rgba(0, 170, 255, 0.3);
}

.logbook-input[readonly] {
    background: rgba(0, 0, 0, 0.3);
    color: #888;
    cursor: not-allowed;
}

select.logbook-input {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%230af' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><polyline points='6 9 12 15 18 9'></polyline></svg>");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 14px;
}

.logbook-actions {
    display: flex;
    gap: 12px;
    margin-top: 15px;
}

.logbook-btn {
    padding: 10px 16px !important;
    border-radius: 6px;
    font-size: 14px !important;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    border: none;
    min-height: 42px;
}

.logbook-btn-primary {
    background: #0af;
    color: #0a0c10;
    flex: 2;
}

.logbook-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 170, 255, 0.3);
}

.logbook-btn-export-all {
    background: rgba(0, 170, 255, 0.2);
    border: 1px solid #0af;
    color: #0af;
    flex: 1;
}

.logbook-btn-export-all:hover {
    background: rgba(0, 170, 255, 0.4);
    transform: translateY(-2px);
}


/* ============================================================ */
/* ===== BARRA DE PROGRESO DEL PASE ===== */
/* ============================================================ */

.pass-progress-container {
    position: relative;
    width: 100%;
    height: 32px;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 16px;
    margin: 6px 0 4px 0;
    overflow: visible;
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-sizing: border-box;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.3);
}

.pass-progress-bar {
    height: 100%;
    width: 0%;
    border-radius: 16px;
    transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1), background 0.6s ease;
    background: linear-gradient(90deg, #0af, #2ecc71);
    box-shadow: 0 0 20px rgba(0, 170, 255, 0.2);
    position: relative;
    z-index: 1;
    min-width: 4px;
}

.pass-progress-bar.waiting {
    background: linear-gradient(90deg, #0a4a6a, #0af);
    box-shadow: 0 0 20px rgba(0, 170, 255, 0.15);
    animation: pulseWaiting 2s ease-in-out infinite;
    width: 2% !important;
}

.pass-progress-bar.active-ascending {
    background: linear-gradient(90deg, #0066ff, #00ccff, #2ecc71);
    box-shadow: 0 0 25px rgba(0, 102, 255, 0.25);
}

.pass-progress-bar.active-mid {
    background: linear-gradient(90deg, #2ecc71, #ffaa00);
    box-shadow: 0 0 25px rgba(46, 204, 113, 0.25);
}

.pass-progress-bar.active-descending {
    background: linear-gradient(90deg, #ffaa00, #ff4444);
    box-shadow: 0 0 25px rgba(255, 170, 0, 0.25);
}

.pass-progress-bar.active-post {
    background: linear-gradient(90deg, #ff4444, #888);
    box-shadow: 0 0 25px rgba(255, 68, 68, 0.15);
}

@keyframes pulseWaiting {
    0%,
    100% {
        opacity: 0.6;
    }
    50% {
        opacity: 1;
    }
}

.pass-milestone {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    font-size: 8px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.3);
    text-shadow: 0 0 10px rgba(0, 0, 0, 0.9);
    font-family: 'Poppins', 'Segoe UI', monospace;
    z-index: 3;
    pointer-events: none;
    letter-spacing: 0.3px;
    text-align: center;
    transition: all 0.5s ease;
}

.pass-milestone .icon {
    font-size: 12px;
    display: block;
    text-align: center;
    line-height: 1.2;
    transition: all 0.5s ease;
}

.pass-milestone .label {
    font-size: 6px;
    display: block;
    text-align: center;
    opacity: 0.8;
    margin-top: 0px;
    line-height: 1.2;
    transition: all 0.5s ease;
}

.pass-milestone.aos {
    left: 4px;
    color: rgba(0, 170, 255, 0.4);
}

.pass-milestone.aos.active {
    color: #0af;
    animation: pulseAOS 1.5s ease-in-out infinite;
}

.pass-milestone.aos.passed {
    color: rgba(0, 170, 255, 0.2);
}

.pass-milestone.aos.passed .icon {
    opacity: 0.3;
}

.pass-milestone.mid {
    left: 50%;
    transform: translate(-50%, -50%);
    color: rgba(255, 255, 255, 0.15);
}

.pass-milestone.mid.active {
    color: #ffaa00;
    font-size: 10px;
}

.pass-milestone.mid.active .icon {
    font-size: 16px;
}

.pass-milestone.mid .label {
    font-size: 7px;
}

.pass-milestone.mid.passed {
    color: rgba(255, 170, 0, 0.2);
}

.pass-milestone.mid::before {
    content: '';
    position: absolute;
    top: -18px;
    left: 50%;
    transform: translateX(-50%);
    width: 2px;
    height: 30px;
    background: rgba(255, 170, 0, 0.1);
    box-shadow: 0 0 10px rgba(255, 170, 0, 0.05);
    transition: all 0.8s ease;
}

.pass-milestone.mid.active::before {
    background: #ffaa00;
    box-shadow: 0 0 20px rgba(255, 170, 0, 0.5);
}

.pass-milestone.los {
    right: 4px;
    color: rgba(255, 68, 68, 0.2);
}

.pass-milestone.los.active {
    color: #ff4444;
    animation: pulseLOS 1.5s ease-in-out infinite;
}

.pass-milestone.los.passed {
    color: #ff4444;
    animation: pulseLOS 1.5s ease-in-out infinite;
}

@keyframes pulseAOS {
    0%,
    100% {
        opacity: 1;
        transform: translateY(-50%) scale(1);
    }
    50% {
        opacity: 0.6;
        transform: translateY(-50%) scale(1.1);
    }
}

@keyframes pulseLOS {
    0%,
    100% {
        opacity: 1;
        transform: translateY(-50%) scale(1);
    }
    50% {
        opacity: 0.5;
        transform: translateY(-50%) scale(0.9);
    }
}

.pass-progress-label {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 9px;
    font-weight: 600;
    color: #ffffff;
    text-shadow: 0 0 10px rgba(0, 0, 0, 0.9);
    white-space: nowrap;
    letter-spacing: 0.5px;
    font-family: 'Poppins', 'Segoe UI', monospace;
    z-index: 2;
    pointer-events: none;
    transition: all 0.3s ease;
}

.pass-progress-percent {
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 8px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.9);
    text-shadow: 0 0 10px rgba(0, 0, 0, 0.9);
    z-index: 2;
    pointer-events: none;
    font-family: 'Poppins', 'Segoe UI', monospace;
}

.pass-progress-elevation {
    position: absolute;
    left: 6px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 7px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.6);
    text-shadow: 0 0 10px rgba(0, 0, 0, 0.9);
    z-index: 2;
    pointer-events: none;
    font-family: 'Poppins', 'Segoe UI', monospace;
}


/* ============================================================ */
/* ===== UNIDADES DEL WIDGET DEL TIEMPO ===== */
/* ============================================================ */

#weather-wind {
    display: inline !important;
}

#weather-wind::after {
    content: ' km/h' !important;
    font-size: inherit !important;
}


/* ============================================================ */
/* ===== APLICAR POPPINS A UBICACIÓN, CLIMA Y HEADER ===== */
/* ============================================================ */

.header-title,
.header-callsign,
.locator-search label,
.locator-search input,
.locator-search button,
.locator-info,
.locator-error,
.weather-widget,
.weather-location,
.weather-temp,
.weather-details div,
.weather-desc,
.weather-updated,
.status,
#selector summary,
#selector summary span,
.sel-controls input,
.sel-controls button,
.sel-info,
.mode-filter-btn,
table,
th,
td,
.btn-principal,
.paypal-header-btn {
    font-family: 'Poppins', 'Segoe UI', 'Courier New', monospace;
}


/* ============================================================ */
/* ===== COLORES RX Y TX EN CABECERA MÓVIL ===== */
/* ============================================================ */

.corrected-freq-header .rx-cor {
    color: #2ecc71 !important;
}

.corrected-freq-header .rx-cor strong {
    color: #ffffff !important;
}

.corrected-freq-header .tx-cor {
    color: #ff4444 !important;
}

.corrected-freq-header .tx-cor strong {
    color: #ffffff !important;
}


/* ============================================================ */
/* ===== EMERGENCIA - FUERZA TODO DENTRO ===== */
/* ============================================================ */

html,
body,
.container,
.sat-card,
.detail-content,
.radar-wrapper,
.map-container {
    max-width: 100% !important;
    overflow-x: hidden !important;
    box-sizing: border-box !important;
}

img,
canvas,
iframe,
video,
svg {
    max-width: 100% !important;
    height: auto !important;
}


/* ============================================================ */
/* ===== RADAR: ESTRUCTURA HORIZONTAL (CORREGIDA) ===== */
/* ============================================================ */

.radar-flex {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 15px !important;
}

.radar-container {
    display: inline-block !important;
    flex: 0 1 auto !important;
    min-width: 0 !important;
    transform-origin: center center;
    cursor: pointer;
}

.radar-canvas {
    max-width: 100% !important;
    height: auto !important;
    display: block !important;
    margin: 0 auto !important;
    will-change: transform;
}

.elev-bar {
    display: inline-block !important;
    flex: 0 0 auto !important;
    width: 14px !important;
    height: 220px !important;
    background: linear-gradient(to top, rgba(0, 170, 255, 0.1), rgba(0, 170, 255, 0.3)) !important;
    border: 1px solid #1a3a5a !important;
    border-radius: 8px !important;
    position: relative !important;
    padding: 3px 0 !important;
}

.elev-marker {
    position: absolute;
    right: -7px;
    width: 10px;
    height: 10px;
    background: #f66;
    clip-path: polygon(100% 50%, 0% 0%, 0% 100%);
    transform: translateY(-50%);
    transition: top 0.3s ease-out;
}

.elev-ticks {
    position: absolute;
    right: -32px;
    top: 0;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.elev-ticks span {
    font-size: 9px;
    color: #888;
}


/* ============================================================ */
/* ===== RESPONSIVE - MÓVIL (menos de 768px) ===== */
/* ============================================================ */

@media (max-width: 768px) {

    /* ---- TABLA OCULTA / TARJETAS VISIBLES ---- */
    .table-wrapper,
    .table-wrapper.visible {
        display: none !important;
    }

    .sat-card,
    #cards-container {
        display: block !important;
        visibility: visible !important;
    }

    .sat-card {
        display: block !important;
    }


    /* ---- SEPARACIÓN ENTRE TARJETAS (30px) ---- */
    #cards-container .sat-card {
        margin-bottom: 40px !important;
        margin-top: 0 !important;
    }

    #cards-container .sat-card:last-child {
        margin-bottom: 0 !important;
    }

    #cards-container {
        padding-bottom: 10px !important;
        display: block !important;
    }


    /* ---- BODY Y CONTENEDOR ---- */
    body {
        font-size: 12.6px;
        padding: 9px;
        overflow-x: hidden !important;
    }

    .container {
        padding: 0 8px !important;
        overflow-x: hidden !important;
    }


    /* ---- HEADER ---- */
    .header-container {
        padding: 30px 0 9px;
        position: relative;
    }

    .header-status span,
    .header-status-dot {
        display: none;
    }

    .header-status {
        position: absolute;
        top: 10px;
        right: 10px;
        left: auto;
        gap: 0;
    }

    .header-home-link {
        display: none !important;
    }

    .paypal-header-btn {
        display: inline-flex !important;
        padding: 4px 10px !important;
        font-size: 9px !important;
        gap: 5px !important;
        min-width: 68px !important;
        border-radius: 24px !important;
        margin-left: 4px !important;
    }

    .header-text {
        margin-top: 5px;
    }

    .header-title {
        font-size: 1.35em !important;
        letter-spacing: 1px !important;
        margin-top: 5px;
    }

    .header-callsign {
        font-size: 1.08em !important;
        letter-spacing: 4px !important;
    }

    .header-callsign::before,
    .header-callsign::after {
        display: none;
    }


    /* ---- BOTONES ---- */
    .btn-principal {
        padding: 8px 18px;
        font-size: 1em;
        width: 100%;
        text-align: center;
    }

    .btn-wrapper {
        justify-content: center;
        margin-bottom: 10px;
    }


    /* ---- DETALLE CONTENT ---- */
    .detail-content {
        grid-template-columns: 1fr;
        gap: 9px;
        padding: 9px;
        overflow: hidden !important;
    }

    .global-map-div,
    .card-global-map-div {
        height: 280px;
        min-height: 280px;
    }


    /* ---- RADAR ---- */
    .button-group {
        gap: 6px;
    }

    .btn-radar {
        padding: 6px 10px;
        font-size: 11px;
        min-height: 34px;
    }

    .btn-radar.record-control {
        min-width: 55px;
    }

    .recording-timer {
        font-size: 10px;
        margin-left: 5px;
        white-space: normal;
        word-break: break-word;
        max-width: 180px;
    }

    .radar-cor-freq {
        gap: 15px;
        flex-wrap: wrap;
        justify-content: center;
    }

    .radar-cor-freq .rx-cor,
    .radar-cor-freq .tx-cor {
        font-size: 14px;
    }

    .time-info {
        font-size: 14px;
    }

    .time-info .utc {
        font-size: 20px;
    }


    /* ---- RADAR FLEX ---- */
    .radar-flex {
        display: flex !important;
        flex-direction: row !important;
        flex-wrap: nowrap !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 8px !important;
    }

    .radar-container {
        flex-shrink: 1 !important;
        min-width: 0 !important;
        max-width: 100% !important;
    }

    .radar-canvas {
        max-width: 100% !important;
        height: auto !important;
        min-width: auto !important;
    }

    .elev-bar {
        height: 150px !important;
        width: 10px !important;
        flex-shrink: 0 !important;
    }

    .elev-ticks {
        right: -24px !important;
    }

    .elev-ticks span {
        font-size: 7px !important;
    }

    .elev-marker {
        right: -5px !important;
        width: 8px !important;
        height: 8px !important;
    }


    /* ---- DOPPLER ---- */
    .doppler-freq-line {
        font-size: 1.2em;
        flex-direction: row;
        align-items: center;
        justify-content: flex-start;
        gap: 8px;
        flex-wrap: wrap;
    }

    .doppler-freq-title,
    .doppler-freq-value,
    .freq-neon-value {
        font-size: 1em;
    }

    .doppler-ctss,
    .doppler-correction {
        font-size: 0.9em;
        margin-left: 5px;
    }


    /* ---- SELECTOR ---- */
    .sel-controls {
        flex-direction: column;
    }

    .sel-controls input {
        min-width: 100%;
    }

    .mode-filters {
        justify-content: center;
        gap: 5px;
    }

    .mode-filter-btn {
        font-size: 0.63rem;
        padding: 3px 9px;
    }

    .sel-list {
        grid-template-columns: 1fr;
        max-height: 250px;
    }

    .sel-actions {
        flex-direction: column;
    }

    .sel-actions button {
        width: 100%;
    }


    /* ---- TARJETAS ---- */
    .sat-card-header {
        flex-direction: row !important;
        justify-content: space-between !important;
        align-items: center !important;
        gap: 7px !important;
        padding: 11px 14px !important;
        flex-wrap: wrap !important;
        border-left: 1px solid #1a3a5a !important;
    }

    .sat-card-header.visible-bg {
        border-left: 1px solid #1a3a5a !important;
    }

    .sat-card-header.warning-bg {
        border-left: 1px solid #1a3a5a !important;
    }

    .sat-card-header.hid-bg {
        border-left: 1px solid #1a3a5a !important;
    }

    .sat-card-name {
        font-size: 0.9rem !important;
        white-space: normal !important;
        word-break: break-word !important;
        flex: 1 !important;
    }

    .sat-card-maxel {
        font-size: 0.9rem !important;
        margin-left: 5px !important;
    }

    .sat-card-maxel-label,
    .sat-card-maxel-value {
        font-size: 0.9rem !important;
    }

    .sat-card-maxel-value {
        font-weight: 700 !important;
    }

    .sat-card-status {
        font-size: 0.58rem !important;
        padding: 3px 9px !important;
        flex-shrink: 0 !important;
    }


    /* ---- SUBINFO DE TARJETA ---- */
    .sat-card-subinfo {
        display: flex !important;
        flex-wrap: nowrap !important;
        align-items: center !important;
        justify-content: flex-start !important;
        gap: 8px !important;
        padding: 6px 14px !important;
    }

    .sat-card-subinfo .sat-card-mode {
        margin: 0 !important;
        flex-shrink: 0 !important;
        font-size: 0.7rem !important;
        padding: 3px 10px !important;
        order: 2 !important;
    }

    .sat-card-subinfo .sat-card-gcal-btn {
        order: 3 !important;
        flex-shrink: 0 !important;
        font-size: 0.6rem !important;
        padding: 3px 10px !important;
        margin-left: auto !important;
    }

    .sat-card-subinfo .aos-local-time-mobile {
        order: 1 !important;
        flex-shrink: 0 !important;
        font-size: 0.7rem !important;
        font-weight: 600 !important;
        color: #88ff88 !important;
        text-shadow: 0 0 8px rgba(136, 255, 136, 0.3) !important;
    }

    .sat-info-item.mobile-mode-hidden {
        display: none !important;
    }


    /* ---- BOTONES DE TARJETA ---- */
    .sat-card-details-btn {
        background: linear-gradient(135deg, rgba(0, 170, 255, 0.15) 0%, rgba(0, 170, 255, 0.05) 100%);
        border: 1px solid #0af;
        color: #0af;
        border-radius: 6px;
        padding: 11px 18px;
        margin-top: 6px;
        width: 100%;
        text-align: center;
        font-weight: 600;
        font-size: 12.6px;
        cursor: pointer;
        transition: all 0.3s;
        min-height: 40px;
    }

    .sat-card-details-btn:hover {
        background: linear-gradient(135deg, rgba(0, 170, 255, 0.25) 0%, rgba(0, 170, 255, 0.1) 100%);
        color: #e0e0e0;
    }

    .hide-details-btn {
        background: linear-gradient(135deg, rgba(0, 170, 255, 0.15) 0%, rgba(0, 170, 255, 0.05) 100%);
        border: 1px solid #0af;
        color: #0af;
        border-radius: 6px;
        padding: 11px 18px;
        margin-top: 9px;
        width: 100%;
        text-align: center;
        font-weight: 600;
        font-size: 12.6px;
        cursor: pointer;
        transition: all 0.3s;
        min-height: 40px;
    }

    .hide-details-btn:hover {
        background: linear-gradient(135deg, rgba(0, 170, 255, 0.25) 0%, rgba(0, 170, 255, 0.1) 100%);
        color: #e0e0e0;
    }


    /* ---- DOPPLER PANEL ---- */
    .doppler-panel {
        grid-template-columns: 1fr;
        gap: 9px;
    }

    .doppler-panel.single-card {
        grid-template-columns: 1fr;
    }

    .doppler-card {
        padding: 11px;
    }


    /* ---- RADAR WRAPPER ---- */
    .radar-wrapper {
        padding: 7px;
        overflow: hidden !important;
    }


    /* ---- SPECTRUM ---- */
    .spectrum-canvas {
        height: 100px;
    }


    /* ---- INFO GRID ---- */
    .sat-info-grid {
        gap: 10px !important;
    }

    .sat-info-label {
        font-size: 11px !important;
    }

    .sat-info-value {
        font-size: 14px !important;
        font-weight: 600 !important;
    }


    /* ---- TABLA (si se muestra) ---- */
    .table-wrapper {
        overflow-x: auto !important;
        margin: 10px -5px !important;
        padding: 0 5px !important;
        width: 100% !important;
    }

    .table-wrapper table {
        min-width: 650px !important;
        width: auto !important;
        font-size: 11px !important;
    }

    .table-wrapper th,
    .table-wrapper td {
        padding: 4px 6px !important;
        font-size: 10px !important;
        white-space: nowrap !important;
    }


    /* ---- LOCATOR SEARCH ---- */
    .locator-search {
        padding: 8px !important;
    }

    .locator-search input {
        width: 100% !important;
        font-size: 11px !important;
        padding: 4px 6px !important;
        color: #ffaa00 !important;
    }

    .locator-search button {
        font-size: 9px !important;
        padding: 4px 8px !important;
    }

    .locator-search label {
        color: #ffffff !important;
    }


    /* ---- WEATHER ---- */
    .weather-main {
        display: flex !important;
        flex-direction: row !important;
        flex-wrap: nowrap !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 8px !important;
        width: 100% !important;
        padding: 4px 0 !important;
    }

    .weather-icon {
        font-size: 22px !important;
        flex-shrink: 0 !important;
        order: 1 !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    .weather-temp {
        font-size: 18px !important;
        font-weight: bold !important;
        flex-shrink: 0 !important;
        order: 2 !important;
        min-width: 50px !important;
        text-align: center !important;
        margin: 0 !important;
        padding: 0 !important;
        color: inherit !important;
        text-shadow: inherit !important;
        transition: color 0.5s ease, text-shadow 0.5s ease !important;
    }

    .weather-location {
        color: #ffffff !important;
    }

    .weather-details {
        display: flex !important;
        flex-direction: row !important;
        flex-wrap: nowrap !important;
        align-items: center !important;
        gap: 6px !important;
        background: rgba(0, 0, 0, 0.15) !important;
        padding: 2px 8px !important;
        border-radius: 6px !important;
        order: 3 !important;
        flex: 0 1 auto !important;
        min-width: 0 !important;
        overflow: hidden !important;
        margin: 0 !important;
    }

    .weather-details div {
        font-size: 8px !important;
        white-space: nowrap !important;
        flex-shrink: 0 !important;
        margin: 0 !important;
        padding: 0 !important;
        line-height: 1.2 !important;
    }

    .weather-details div#wind-row {
        font-size: 0 !important;
    }

    .weather-details div#wind-row span {
        font-size: 8px !important;
    }

    .weather-details div#wind-row span#weather-wind::after {
        content: ' km/h' !important;
        font-size: 8px !important;
    }

    .weather-left {
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        gap: 4px !important;
        flex-shrink: 0 !important;
        order: 1 !important;
    }


    /* ---- LOGBOOK ---- */
    .logbook-section-content {
        padding: 10px;
    }

    .logbook-form-row {
        grid-template-columns: 1fr !important;
        gap: 10px;
        margin-bottom: 10px;
    }

    .logbook-input {
        padding: 8px 10px !important;
        font-size: 13px !important;
    }

    .logbook-form-group label {
        font-size: 12px !important;
    }

    .logbook-btn {
        padding: 8px 14px !important;
        font-size: 13px !important;
        min-height: 38px;
    }

    .logbook-actions {
        flex-direction: column;
    }

    .logbook-btn {
        width: 100%;
    }


    /* ---- BARRA DE PROGRESO ---- */
    .pass-progress-container {
        height: 32px;
        margin: 5px 0 3px 0;
        border-radius: 16px;
    }

    .pass-progress-label {
        font-size: 8px;
    }

    .pass-progress-percent {
        font-size: 7px;
        right: 4px;
    }

    .pass-progress-elevation {
        font-size: 6px;
        left: 4px;
    }

    .pass-milestone {
        font-size: 7px;
    }

    .pass-milestone .icon {
        font-size: 10px;
    }

    .pass-milestone .label {
        font-size: 5px;
    }

    .pass-milestone.mid.active {
        font-size: 8px;
    }

    .pass-milestone.mid.active .icon {
        font-size: 14px;
    }

    .pass-milestone.mid::before {
        height: 24px;
        top: -14px;
    }


    /* ---- BORDES Y SOMBRAS ---- */
    .sat-card {
        border: 1px solid rgba(26, 58, 90) !important;
        box-shadow: 0 1px 20px rgba(0, 0, 0, ) !important;
    }

    .sat-card:not(:last-child) {
        margin-bottom: 30px !important;
    }

    .sat-card:active {
        transform: scale(0.99) !important;
        transition: transform 0.1s ease !important;
    }

    .sat-card-header {
        border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
    }
}


/* ============================================================ */
/* ===== RESPONSIVE - TABLET (769px a 1024px) ===== */
/* ============================================================ */

@media (min-width: 769px) and (max-width: 1024px) {
    .container {
        max-width: 100%;
        padding: 0 12px;
    }

    .header-title {
        font-size: 1.62em !important;
        letter-spacing: 2px !important;
    }

    .header-callsign {
        font-size: 1.26em !important;
        letter-spacing: 6px !important;
    }

    .header-status {
        display: flex;
        right: 10px;
        gap: 8px;
    }

    .header-home-link {
        font-size: 16px;
    }

    .btn-principal {
        padding: 6px 16px;
        font-size: 0.85em;
    }

    table {
        font-size: 13px;
    }

    th,
    td {
        padding: 6px 8px;
    }

    .detail-content {
        grid-template-columns: 1fr;
        gap: 13px;
    }

    .global-map-div,
    .card-global-map-div {
        height: 320px;
    }

    .time-info {
        font-size: 16px;
    }

    .time-info .utc {
        font-size: 18px;
    }

    .doppler-freq-line {
        font-size: 1.2em;
        gap: 18px;
    }

    .doppler-freq-title,
    .doppler-freq-value,
    .freq-neon-value {
        font-size: 2em;
    }

    .doppler-ctss,
    .doppler-correction {
        font-size: 1em;
    }

    .radar-flex {
        gap: 12px !important;
    }

    .elev-bar {
        height: 200px !important;
        width: 12px !important;
    }

    .logbook-form-row {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}


/* ============================================================ */
/* ===== RESPONSIVE - ESCRITORIO (más de 769px) ===== */
/* ============================================================ */

@media (min-width: 769px) {

    /* ---- LOCATOR SEARCH ---- */
    .locator-search {
        flex-direction: row !important;
        flex-wrap: wrap !important;
        justify-content: center !important;
        gap: 15px !important;
        padding: 10px 20px !important;
    }

    .locator-search label {
        margin: 0 !important;
        flex-shrink: 0 !important;
        font-size: 14px !important;
        color: #ffffff !important;
    }

    .locator-search .locator-input-wrapper {
        width: auto !important;
        flex-shrink: 0 !important;
    }

    .locator-search input {
        width: 120px !important;
        font-size: 14px !important;
        padding: 10px 12px !important;
        color: #ffaa00 !important;
    }

    .locator-search .buttons-group button {
        padding: 8px 18px !important;
        font-size: 13px !important;
    }

    .locator-search button#btn-default {
        font-size: 13px !important;
    }

    .locator-search button#btn-default::before {
        content: none !important;
    }

    .locator-info {
        font-size: 13px !important;
        flex-shrink: 0 !important;
        margin-left: 0 !important;
    }


    /* ---- WEATHER ---- */
    .weather-widget {
        padding: 10px 15px !important;
    }

    .weather-header {
        display: flex !important;
        justify-content: center !important;
        align-items: center !important;
        position: relative !important;
        border-bottom: 1px solid #1a3a5a !important;
        padding-bottom: 8px !important;
        margin-bottom: 10px !important;
    }

    .weather-location {
        font-size: 14px !important;
        text-align: center !important;
        flex: 1 !important;
        color: #ffffff !important;
    }

    .weather-updated {
        display: none !important;
    }

    .weather-main {
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 30px !important;
        flex-wrap: nowrap !important;
    }

    .weather-icon {
        font-size: 48px !important;
        order: 1 !important;
    }

    .weather-temp {
        font-size: 32px !important;
        order: 2 !important;
        min-width: 100px !important;
    }

    .weather-details {
        display: flex !important;
        flex-direction: row !important;
        gap: 25px !important;
        background: rgba(0, 0, 0, 0.2) !important;
        padding: 8px 20px !important;
        border-radius: 8px !important;
        order: 3 !important;
    }

    .weather-details div {
        font-size: 12px !important;
        white-space: nowrap !important;
    }

    .weather-desc {
        display: none !important;
    }


    /* ---- TABLA Y TARJETAS ---- */
    .table-wrapper,
    .table-wrapper.visible {
        display: block !important;
    }

    .sat-card,
    #cards-container {
        display: none !important;
        visibility: hidden !important;
    }

    .sat-name-link {
        white-space: nowrap !important;
        display: inline-flex !important;
        align-items: center !important;
        gap: 6px !important;
    }

    .satellite-name-cell {
        white-space: nowrap !important;
    }

    .max-el-display {
        white-space: nowrap !important;
        margin-left: 12px !important;
    }

    .pass-progress-container {
        display: none !important;
    }


    /* ---- BORDES DE TABLA ---- */
    .table-wrapper table {
        border-color: rgba(255, 255, 255, 0.08) !important;
    }

    .table-wrapper th,
    .table-wrapper td {
        border-color: rgba(255, 255, 255, 0.06) !important;
    }
}


/* ============================================================ */
/* ===== FORZAR TARJETAS EN ESCRITORIO (OPCIONAL) ===== */
/* ============================================================ */

/*
   Descomenta este bloque si quieres ver las tarjetas también en escritorio
   
   @media (min-width: 769px) {
       .table-wrapper,
       .table-wrapper.visible {
           display: none !important;
       }
       .sat-card,
       #cards-container {
           display: block !important;
           visibility: visible !important;
       }
       .sat-card {
           display: block !important;
           max-width: 800px !important;
           margin: 0 auto 30px auto !important;
       }
   }
*/
/* ============================================================ */
/* ===== BORDE RESPLANDECIENTE EN TARJETAS (MÓVIL) ===== */
/* ============================================================ */

@media (max-width: 768px) {
    /* Borde resplandeciente sutil en todas las tarjetas */
    .sat-card {
        border: 1px solid rgba(0, 170, 255, 0.15) !important;
        box-shadow: 
            0 0 15px rgba(0, 170, 255, 0.05),
            0 0 30px rgba(0, 170, 255, 0.02),
            inset 0 0 30px rgba(0, 170, 255, 0.02) !important;
        transition: box-shadow 0.4s ease, border-color 0.4s ease !important;
    }
    
    /* Efecto al pasar el dedo (o hover en escritorio) */
    .sat-card:active {
        box-shadow: 
            0 0 25px rgba(0, 170, 255, 0.15),
            0 0 50px rgba(0, 170, 255, 0.05),
            inset 0 0 30px rgba(0, 170, 255, 0.03) !important;
        border-color: rgba(0, 170, 255, 0.3) !important;
    }
    
    /* Cada estado de la tarjeta con su propio color de resplandor */
    
    /* Tarjeta VISIBLE (verde) */
    .sat-card-header.visible-bg ~ .sat-card {
        border-color: rgba(46, 204, 113, 0.2) !important;
        box-shadow: 
            0 0 20px rgba(46, 204, 113, 0.08),
            0 0 40px rgba(46, 204, 113, 0.03),
            inset 0 0 30px rgba(46, 204, 113, 0.02) !important;
    }
    
    /* Tarjeta WARNING (amarillo) */
    .sat-card-header.warning-bg ~ .sat-card {
        border-color: rgba(255, 170, 0, 0.2) !important;
        box-shadow: 
            0 0 20px rgba(255, 170, 0, 0.08),
            0 0 40px rgba(255, 170, 0, 0.03),
            inset 0 0 30px rgba(255, 170, 0, 0.02) !important;
    }
    
    /* Tarjeta HID (azul) */
    .sat-card-header.hid-bg ~ .sat-card {
        border-color: rgba(0, 170, 255, 0.15) !important;
        box-shadow: 
            0 0 20px rgba(0, 170, 255, 0.05),
            0 0 40px rgba(0, 170, 255, 0.02),
            inset 0 0 30px rgba(0, 170, 255, 0.02) !important;
    }
}
