@charset "utf-8";
/* CSS Document */
@charset "utf-8";

/*  Copyright (c) 2025 ON3WBK - Laureys Marnix - on3wbk@lama-projects.be      */
/*                                                                              */
/*  This file is part of the ON3WBK E-QSL PROJECT                               */
/*                                                                              */
/*  Permission is hereby granted to view and use this code for personal or      */
/*  educational purposes only. Redistribution, modification, or commercial      */
/*  use of this file, in whole or in part, is strictly prohibited without       */
/*  prior written permission from the copyright holder.                         */
/*                                                                              */
/*  Unauthorized copying of this file, via any medium, is strictly prohibited.  */
/*  2025 - 2035 All rights reserved.                                            */

/* ===== FIX FOR BLUE LINE AT TOP OF PAGE ===== */
html, body {
    border: none !important;
    margin: 0 !important;
    padding: 0 !important;
    outline: none !important;
}

/* Remove ALL top borders that could cause the blue line */
body.mx-auto.fonts-loaded {
    border-top: none !important;
}

.eqsl-app { 
    max-width: 1000px; 
    margin: auto; 
    border-top: none !important;
    padding-bottom: 40px; /* Added padding to create space above footer */
    position: relative;
    min-height: calc(100vh - 200px); /* Ensure minimum height */
}
.text-strong { font-weight: bold; }

body { 
    background-color: #FCFCE6 !important; 
    color: #333; 
    margin: 0;
    padding: 0;
    border: none !important;
    padding-bottom: 140px !important; /* Increased from 120px to 140px */
    min-height: 100vh;
    position: relative;
}
.bg-light { background-color: #fff !important; color: #333 !important; }
.text-bg-secondary { background-color: #e9ecef !important; color: #333 !important; border-color: #dee2e6 !important; }
.border-secondary { border-color: #dee2e6 !important; }

.dark-mode { 
    background-color: #000000 !important; 
    color: #fff; 
    border: none !important;
}
.dark-mode .bg-light { background-color: #2d2d2d !important; color: #fff !important; }
.dark-mode .text-bg-secondary { background-color: #444 !important; color: #fff !important; border-color: #555 !important; }
.dark-mode .border-secondary { border-color: #555 !important; }

.canvas-container {
    border: 2px solid #dee2e6;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    width: 1000px;
    height: 611px;
        background: white;
    position: relative;
    z-index: 1;
    overflow: visible !important; /* Ensure canvas is fully visible */
}
.dark-mode .canvas-container {
    border-color: #555;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
}

.form-control-color { width: 50px; padding: 0; }
.btn.active { background-color: #0d6efd !important; color: white !important; }
.header-logo { 
    width: 340px; 
    height: 48px; 
    object-fit: contain;
}

/* === MINIMAL FIX FOR DROPDOWN WIDTHS === */
/* BAND dropdown - wide enough to show all band names */
.band-dropdown {
    min-width: 120px !important;
    max-width: 120px !important;
    width: 120px !important;
}

/* MODE dropdown - wide enough to show mode names */
.mode-input {
    min-width: 160px !important;
    max-width: 160px !important;
    width: 160px !important;
}

/* RST dropdowns - wide enough to show dB values */
.rst-dropdown {
    min-width: 100px !important;
    max-width: 120px !important;
}

.pwr-dropdown {
    min-width: 100px;
}

.theme-btn {
    min-width: 70px;
    font-weight: bold;
}

.qso-with-container .input-group {
    margin-right: 0px;
    width: 100%;
}

.row.pt-4 {
    align-items: flex-start;
}

.qso-with-container {
    padding-right: 5px;
}

.qsl-btn {
    background-color: transparent !important;
    border-color: #6c757d !important;
    color: #6c757d !important;
}
.qsl-btn.active {
    background-color: #0d6efd !important;
    border-color: #0d6efd !important;
    color: white !important;
}

.confirming-buttons-container {
    min-width: 250px !important;
    max-width: 250px !important;
}

.confirming-buttons-container .btn {
    white-space: nowrap !important;
    line-height: 1.5 !important;
    text-align: center;
    font-size: 0.8rem;
    padding: 0.4rem 0.6rem !important;
    height: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 1;
}

.confirm-btn {
    background-color: transparent !important;
    border-color: #6c757d !important;
    color: #6c757d !important;
}
.confirm-btn.active {
    background-color: #0d6efd !important;
    border-color: #0d6efd !important;
    color: white !important;
}

.qrz-confirm-btn {
    background-color: #17a2b8 !important;
    border-color: #17a2b8 !important;
    color: white !important;
    font-size: 0.8rem;
    padding: 0.4rem 0.6rem !important;
    white-space: nowrap;
}

.address-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1050;
    justify-content: center;
    align-items: center;
}
.address-modal-content {
    background-color: white;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    width: 90%;
    max-width: 600px;
    max-height: 90vh;
    overflow-y: auto;
}
.dark-mode .address-modal-content {
    background-color: #2d2d2d;
    color: white;
}
.address-form-title {
    text-align: center;
    margin-bottom: 20px;
    font-weight: bold;
    color: #0d6efd;
}
.address-form-buttons {
    display: flex;
    justify-content: space-between;
    margin-top: 20px;
}
.address-form-buttons .btn {
    flex: 1;
    margin: 0 5px;
}

/* Card Gallery Styling */
.gallery-folders-container {
    max-height: 400px;
    overflow-y: auto;
}

.folder-card {
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    height: 100%;
}

.folder-card:hover {
    transform: translateY(-2px);
    border-color: #0d6efd;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.dark-mode .folder-card {
    background-color: #3d3d3d;
    color: white;
}

.dark-mode .folder-card:hover {
    background-color: #4d4d4d;
}

.image-card {
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.image-card:hover {
    transform: translateY(-2px);
    border-color: #0d6efd;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.dark-mode .image-card {
    background-color: #3d3d3d;
    color: white;
}

.gallery-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 1px solid #dee2e6;
}

.dark-mode .gallery-nav {
    border-bottom-color: #555;
}

.flag-icon {
    width: 60px;
    height: 40px;
    object-fit: cover;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    margin-bottom: 8px;
}

.folder-icon {
    font-size: 2rem;
    color: #ffc107;
    margin-bottom: 8px;
}

.email-modal-content {
    background-color: white;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    width: 90%;
    max-width: 600px;
    max-height: 90vh;
    overflow-y: auto;
    border: 2px solid #dee2e6;
}

.dark-mode .email-modal-content {
    background-color: #2d2d2d;
    color: white;
    border-color: #555;
}

.email-form-title {
    text-align: center;
    margin-bottom: 20px;
    font-weight: bold;
    color: #0d6efd;
}

.email-form-group {
    margin-bottom: 15px;
}

.email-form-group label {
    font-weight: bold;
    margin-bottom: 5px;
    display: block;
}

.email-form-control {
    background-color: white;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    padding: 8px 12px;
    width: 100%;
    color: #333;
    font-size: 1rem;
}

.dark-mode .email-form-control {
    background-color: #3d3d3d;
    border-color: #555;
    color: white;
}

.email-textarea {
    min-height: 100px;
    resize: vertical;
}

.email-preview {
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    padding: 15px;
    margin: 15px 0;
    font-style: italic;
    font-size: 0.9rem;
}

.dark-mode .email-preview {
    background-color: #3d3d3d;
    border-color: #555;
}

.email-attachment {
    display: flex;
    align-items: center;
    background-color: #f8f9fa;
    padding: 12px;
    border-radius: 4px;
    margin: 15px 0;
    border: 1px solid #dee2e6;
}

.dark-mode .email-attachment {
    background-color: #3d3d3d;
    border-color: #555;
}

.email-attachment i {
    font-size: 1.5rem;
    margin-right: 12px;
    color: #198754;
}

.email-form-buttons {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    margin-top: 20px;
}

.email-form-buttons .btn {
    flex: 1;
    padding: 10px;
    font-weight: bold;
}

.btn-email-send {
    background-color: #198754;
    border-color: #198754;
    color: white;
}

.btn-email-send:hover {
    background-color: #157347;
    border-color: #146c43;
}

.btn-email-cancel {
    background-color: #6c757d;
    border-color: #6c757d;
    color: white;
}

.btn-email-cancel:hover {
    background-color: #5a6268;
    border-color: #545b62;
}

/* Status messages */
.email-status {
    padding: 12px;
    border-radius: 5px;
    margin: 15px 0;
    text-align: center;
    font-weight: bold;
}

.email-status.loading {
    background-color: #fff3cd;
    border: 1px solid #ffeaa7;
    color: #856404;
}

.email-status.success {
    background-color: #d1edff;
    border: 1px solid #b3d9ff;
    color: #004085;
}

.email-status.error {
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
}

.email-btn-disabled {
    background-color: #6c757d !important;
    border-color: #6c757d !important;
    color: white !important;
    cursor: not-allowed !important;
    opacity: 0.6;
}

#qso-details-container {
    margin-top: 0;
    padding-bottom: 20px; /* RUIMTE TOEGEVOEGD ONDERAAN */
}

#my-details-container {
    margin-top: 0;
    padding-bottom: 15px; /* EXTRA RUIMTE ONDERAAN TOEGEVOEGD */
}

#my-addons-container {
    margin-top: 0;
}

.hrd-style {
    background: linear-gradient(to bottom, #f0f0f0, #e0e0e0) !important;
    border: 2px solid #a0a0a0 !important;
    border-radius: 5px !important;
    box-shadow: 2px 2px 5px rgba(0,0,0,0.2) !important;
}

.hrd-style .input-group-text {
    background: linear-gradient(to bottom, #4a6ea9, #3a5a8c) !important;
    color: white !important;
    font-weight: bold !important;
    border: 1px solid #2a4a7c !important;
    min-width: 100px;
}

.hrd-style .form-control, .hrd-style .form-select {
    background-color: #ffffe0 !important;
    border: 1px solid #a0a0a0 !important;
    font-weight: bold;
    color: #000080;
}

.hrd-style .btn {
    background: linear-gradient(to bottom, #e0e0e0, #c0c0c0) !important;
    border: 1px solid #808080 !important;
    color: #000080 !important;
    font-weight: bold;
}

.hrd-style .btn:hover {
    background: linear-gradient(to bottom, #d0d0d0, #b0b0b0) !important;
}

.hrd-style .btn.active {
    background: linear-gradient(to bottom, #4a6ea9, #3a5a8c) !important;
    color: white !important;
    border-color: #2a4a7c !important;
}

.hrd-section-header {
    background: linear-gradient(to bottom, #4a6ea9, #3a5a8c) !important;
    color: white !important;
    font-weight: bold;
    padding: 5px 10px;
    border-radius: 3px 3px 0 0;
    text-align: center;
    margin-bottom: 10px;
}

.dark-mode .hrd-style {
    background: linear-gradient(to bottom, #404040, #303030) !important;
    border: 2px solid #606060 !important;
}

.dark-mode .hrd-style .input-group-text {
    background: linear-gradient(to bottom, #3a5a8c, #2a4a7c) !important;
    border: 1px solid #1a3a6c !important;
}

.dark-mode .hrd-style .form-control, .dark-mode .hrd-style .form-select {
    background-color: #202020 !important;
    color: #a0a0ff !important;
    border: 1px solid #606060 !important;
}

.dark-mode .hrd-style .btn {
    background: linear-gradient(to bottom, #606060, #505050) !important;
    border: 1px solid #404040 !important;
    color: #a0a0ff !important;
}

.dark-mode .hrd-style .btn.active {
    background: linear-gradient(to bottom, #3a5a8c, #2a4a8c) !important;
    color: white !important;
}

.freq-input {
    max-width: 120px !important;
}

.btn-sm-custom {
    padding: 0.25rem 0.5rem !important;
    font-size: 0.75rem !important;
}

.rst-input {
    max-width: 70px !important;
    min-width: 70px !important;
}

.rst-btn {
    width: 50px !important;
    min-width: 50px !important;
    max-width: 50px !important;
    text-align: center;
    padding-left: 0 !important;
    padding-right: 0 !important;
}

.rst-sent-container {
    margin-right: 15px; /* Meer ruimte tussen RST_SENT en RST_RCVD */
}

.rst-rcvd-container {
    margin-left: -30px; /* RST_RCVD MEER NAAR LINKS GESCHOVEN */
}

.cq-zone-input {
    max-width: 80px !important;
    min-width: 80px !important;
}

.itu-zone-input {
    max-width: 80px !important;
    min-width: 80px !important;
}

.grid-input {
    max-width: 100px !important;
    min-width: 100px !important;
}

.qsl-buttons-container {
    min-width: 200px !important;
    max-width: 200px !important;
}

.qsl-buttons-container .btn {
    white-space: nowrap !important;
    line-height: 1.5 !important;
    text-align: center;
    font-size: 0.8rem;
    padding: 0.4rem 0.6rem !important;
    height: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 1;
}

.addons-buttons-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    flex-wrap: wrap;
    gap: 10px;
}

.addons-left-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.addons-right-buttons {
    display: flex;
    gap: 8px;
    align-items: center;
}

.button-group {
    display: flex;
    align-items: center;
    gap: 4px;
}

.qrz-login-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1060;
    justify-content: center;
    align-items: center;
}
.qrz-login-content {
    background-color: white;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    width: 90%;
    max-width: 400px;
}
.dark-mode .qrz-login-content {
    background-color: #2d2d2d;
    color: white;
}
.qrz-login-title {
    text-align: center;
    margin-bottom: 20px;
    font-weight: bold;
    color: #0d6efd;
}
.qrz-form-group {
    margin-bottom: 15px;
}
.qrz-form-group label {
    font-weight: bold;
    margin-bottom: 5px;
    display: block;
}
.qrz-form-control {
    background-color: white;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    padding: 8px 12px;
    width: 100%;
    color: #333;
    font-size: 1rem;
}
.dark-mode .qrz-form-control {
    background-color: #3d3d3d;
    border-color: #555;
    color: white;
}
.qrz-form-buttons {
    display: flex;
    justify-content: space-between;
    margin-top: 20px;
}
.qrz-form-buttons .btn {
    flex: 1;
    margin: 0 5px;
}
.qrz-status {
    padding: 10px;
    border-radius: 5px;
    margin: 10px 0;
    text-align: center;
    font-weight: bold;
    display: none;
}
.qrz-status.loading {
    background-color: #fff3cd;
    border: 1px solid #ffeaa7;
    color: #856404;
}
.qrz-status.success {
    background-color: #d1edff;
    border: 1px solid #b3d9ff;
    color: #004085;
}
.qrz-status.error {
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
}
.addons-buttons-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    flex-wrap: nowrap;
    gap: 8px;
    padding: 5px 0;
}
/* QRZ Login Modal voor Station Details */
.qrz-login-modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
    align-items: center;
    justify-content: center;
}

.qrz-login-content {
    background-color: #fefefe;
    padding: 20px;
    border-radius: 8px;
    width: 90%;
    max-width: 400px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.qrz-login-title {
    margin-bottom: 20px;
    color: #333;
    font-size: 1.5rem;
}

.qrz-form-group {
    margin-bottom: 15px;
}

.qrz-form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
    color: #555;
}

.qrz-form-control {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.qrz-form-buttons {
    display: flex;
    justify-content: space-between;
    margin-top: 20px;
}

.qrz-status {
    padding: 10px;
    border-radius: 4px;
    margin-bottom: 15px;
    display: none;
}

.qrz-status.loading {
    background-color: #d1ecf1;
    color: #0c5460;
    border: 1px solid #bee5eb;
}

.qrz-status.success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.qrz-status.error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* Additional styles for reply functionality */
.reply-highlight {
    background-color: #e8f5e9 !important;
    border-color: #4caf50 !important;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(76, 175, 80, 0.4); }
    70% { box-shadow: 0 0 0 10px rgba(76, 175, 80, 0); }
    100% { box-shadow: 0 0 0 0 rgba(76, 175, 80, 0); }
}

.reply-notification {
    background: linear-gradient(45deg, #e3f2fd, #bbdefb) !important;
    border-left: 4px solid #2196f3 !important;
    border-radius: 8px !important;
    box-shadow: 0 2px 10px rgba(33, 150, 243, 0.1) !important;
}

.reply-notification .btn-close {
    padding: 1rem;
}

.reply-mode-badge {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
    background: linear-gradient(45deg, #ff9800, #ff5722);
    color: white;
    padding: 8px 15px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: bold;
    box-shadow: 0 4px 12px rgba(255, 152, 0, 0.3);
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-5px); }
}

.email-status.loading {
    background: #fff3cd;
    border-color: #ffc107;
    color: #856404;
}

.email-status.success {
    background: #d4edda;
    border-color: #c3e6cb;
    color: #155724;
}

.email-status.error {
    background: #f8d7da;
    border-color: #f5c6cb;
    color: #721c24;
}

.email-status {
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    display: none;
}

.reply-callsign {
    fill: #e91e63 !important;
    font-weight: 900 !important;
    transition: all 0.3s ease;
}

#QSO_DATE {
    width: 115px !important;
    min-width: 115px !important;
    max-width: 115px !important;
}

/* Fix for QSO_CALLSIGN input field alignment */
#QSO_CALLSIGN {
    width: auto !important; /* Allow natural width */
    min-width: 200px !important; /* Minimum width */
    flex: 1 !important; /* Take available space */
}

/* Style for TODAY and NOW buttons container */
.date-time-buttons {
    display: flex;
    gap: 5px;
    align-items: center;
    white-space: nowrap;
}

/* TODAY and NOW buttons specific styling */
.today-btn, .now-btn {
    min-width: 70px !important;
    padding: 0.25rem 0.5rem !important;
    font-size: 0.8rem !important;
    white-space: nowrap;
}

/* Fix for zoom layout breaking */
.eqsl-app {
    min-width: 1000px;
}

.qso-details-container {
    min-width: 950px;
    overflow-x: visible;
}

.row.first-row {
    display: flex;
    flex-wrap: nowrap !important;
    white-space: nowrap;
    min-width: 900px;
    overflow-x: visible;
}

.row.first-row .col-4 {
    flex: 0 0 auto;
    width: auto;
    margin-right: 15px;
}

.row.first-row .col-4:last-child {
    margin-right: 0;
}

.date-container .input-group,
.time-container .input-group {
    min-width: 280px;
    flex-wrap: nowrap;
}

.qso-with-container .input-group {
    min-width: 250px;
    flex-wrap: nowrap;
}

/* Prevent input groups from wrapping */
.input-group {
    flex-wrap: nowrap !important;
}

/* Ensure buttons stay inline */
.btn-outline-secondary {
    white-space: nowrap;
}

/* Band and Mode rows also need fixing */
.row.mt-4:not(.first-row) {
    min-width: 850px;
    overflow-x: visible;
}

/* ===== NEW FIXED FOOTER STYLES ===== */
.simple-footer {
    position: fixed !important;
    bottom: 0 !important;
    left: 0 !important;
    width: 100% !important;
    padding: 12px 0 !important;
    z-index: 1000 !important;
    border-top: none !important; /* Ensure no top border */
    background-color: #FCFCE6 !important; /* Default light mode */
    height: auto !important; /* Auto height for content */
}

.footer-content {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 15px;
    text-align: center;
}

.footer-text {
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 8px;
}

/* Light mode footer */
.light-mode .simple-footer {
    background-color: #FCFCE6 !important;
    color: #6c757d;
}

.light-mode .footer-text {
    color: #6c757d;
}

/* Dark mode footer */
.dark-mode .simple-footer {
    background-color: #000000 !important;
    color: #adb5bd;
}

.dark-mode .footer-text {
    color: #adb5bd;
}

/* Ensure canvas itself is fully visible */
canvas#canvas {
    display: block !important;
    max-width: 100%;
    height: auto;
}

/* Remove any transform or translate that might affect positioning */
.canvas-container * {
    transform: none !important;
}

/* Ensure all sections have proper stacking context */
section, div[class*="container"] {
    position: relative;
    z-index: auto;
}

/* Fix for any potential parent container clipping */
.eqsl-app > div {
    overflow: visible !important;
}

/* Specific fix for the canvas wrapper */
.canvas-container-wrapper {
    position: relative;
    min-height: 650px; /* Minimum height to ensure canvas space */
    margin-bottom: 20px;
}

/* Add a clearfix after the canvas */
.canvas-container:after {
    content: '';
    display: table;
    clear: both;
}

/* Responsive adjustments */
@media (max-width: 1200px) {
    .first-row {
        flex-wrap: wrap;
    }
    
    .first-row .col-4 {
        width: 100% !important;
        margin-bottom: 10px;
    }
    
    /* FIX: Don't force 100% width on date/time and callsign inputs */
    #QSO_DATE, #QSO_TIME {
        width: auto !important;
        min-width: 120px !important;
        max-width: 150px !important;
    }
    
    #QSO_CALLSIGN {
        width: auto !important;
        min-width: 200px !important;
        flex: 1 !important;
    }
    
    /* Responsive dropdown widths */
    .band-dropdown {
        min-width: 120px !important;
        max-width: 150px !important;
    }
    
    .mode-input {
        min-width: 120px !important;
        max-width: 150px !important;
    }
    
    .freq-input{
        min-width: 120px !important;
        max-width: 150px !important;
    }
    
    .btn-sm-custom {
        padding: 0.2rem 0.4rem !important;
        font-size: 0.7rem !important;
    }
    
    .rst-sent-container, .rst-rcvd-container {
        margin: 0 !important;
        width: 100% !important;
    }
    
    .rst-rcvd-container {
        margin-top: 10px !important;
    }
    
    .addons-buttons-container {
        flex-wrap: wrap !important;
    }
    
    .addons-left-buttons, .addons-right-buttons {
        width: 100% !important;
        justify-content: center !important;
        margin-bottom: 10px;
    }
    
    .button-group {
        margin-bottom: 5px;
    }
    
    /* Ensure TODAY/NOW buttons stay inline */
    .date-time-buttons {
        display: flex;
        flex-wrap: nowrap;
        gap: 5px;
    }
    
    .canvas-container {
        margin-top: 0;
        padding-top: 0;
        position: relative;
        width: 1000px;
        height: 611px;
        overflow: hidden;
        margin: 0 auto;
        background-color: transparent;
    }
    
    canvas#canvas {
        width: 100% !important;
        height: auto !important;
    }
}

@media (max-width: 768px) {
    .canvas-container {
        width: 100% !important;
        height: auto !important;
        aspect-ratio: 1000/611;
        margin: 15px auto !important;
    }
    
    canvas#canvas {
        width: 100% !important;
        height: auto !important;
    }
    
    .eqsl-app {
        padding: 0 10px;
        padding-bottom: 50px; /* More padding on mobile */
        min-height: calc(100vh - 250px);
    }
    
    .header-logo {
        width: 250px !important;
        height: auto !important;
    }
    
    .hrd-style .input-group-text {
        min-width: 80px !important;
        font-size: 0.8rem;
    }
    
    /* Mobile dropdown widths */
    .band-dropdown {
        min-width: 100px !important;
        max-width: 130px !important;
    }
    
    .mode-input {
        min-width: 100px !important;
        max-width: 130px !important;
    }
    
    .qsl-buttons-container, .confirming-buttons-container {
        min-width: 150px !important;
        max-width: 150px !important;
    }
    
    .qsl-buttons-container .btn, .confirming-buttons-container .btn {
        font-size: 0.7rem !important;
        padding: 0.3rem 0.4rem !important;
    }
    
    .qrz-confirm-btn {
        font-size: 0.7rem !important;
        padding: 0.3rem 0.4rem !important;
        white-space: normal !important;
        text-align: center;
    }
    
    /* Adjust date/time inputs for smaller screens */
    #QSO_DATE, #QSO_TIME {
        min-width: 100px !important;
        max-width: 120px !important;
    }
    
    #QSO_CALLSIGN {
        min-width: 150px !important;
    }
    
    .today-btn, .now-btn {
        min-width: 60px !important;
        font-size: 0.7rem !important;
        padding: 0.2rem 0.3rem !important;
    }
    
    body {
        padding-bottom: 160px !important; /* More space for mobile footer */
    }
    
    .simple-footer {
        padding: 10px 0 !important;
    }
    
    .footer-text {
        font-size: 12px;
    }
    
    .footer-buttons .btn {
        font-size: 12px;
        padding: 4px 8px;
    }
}

@media (max-width: 576px) {
    body {
        font-size: 14px;
        padding-bottom: 180px !important; /* Even more space for small screens */
    }
    
    .hrd-section-header {
        font-size: 1rem;
        padding: 3px 8px;
    }
    
    .form-control, .form-select {
        font-size: 0.9rem !important;
    }
    
    .btn {
        font-size: 0.8rem !important;
    }
    
    .reply-mode-badge {
        font-size: 0.7rem;
        padding: 5px 10px;
        top: 10px;
        right: 10px;
    }
    
    /* Stack date/time and callsign inputs on very small screens */
    #QSO_DATE, #QSO_TIME, #QSO_CALLSIGN {
        width: 100% !important;
        min-width: 100% !important;
        max-width: 100% !important;
        margin-bottom: 5px;
    }
    
    .date-time-buttons {
        width: 100%;
        justify-content: center;
        margin-top: 5px;
    }
    
    /* Responsive fallback for zoom layout */
    .eqsl-app {
        min-width: 700px;
        padding-bottom: 60px;
        min-height: calc(100vh - 300px);
    }
    
    .qso-details-container {
        min-width: 650px;
    }
    
    .row.first-row {
        min-width: 600px;
        flex-wrap: wrap !important;
    }
    
    .row.first-row .col-4 {
        width: 100%;
        margin-right: 0;
        margin-bottom: 10px;
    }
    
    .footer-text {
        font-size: 11px;
    }
    
    .footer-content {
        padding: 0 10px;
    }
    
    .simple-footer {
        padding: 8px 0 !important;
    }
}

/* Ad banner styles */
.hidden-ad-banner {
    display: none;
    width: 0;
    height: 0;
    border: none;
}

.ad-banner-iframe {
    width: 100%;
    height: 100px;
    border: none;
    display: block;
}

/* Email button states */
.email-btn-disabled {
    background-color: #6c757d !important;
    border-color: #6c757d !important;
    color: white !important;
    cursor: not-allowed !important;
    opacity: 0.6;
}

/* Theme button active states */
.btn-warning.active {
    background-color: #ffc107 !important;
    border-color: #ffc107 !important;
    color: #000 !important;
}

.btn-outline-primary.active {
    background-color: #0d6efd !important;
    border-color: #0d6efd !important;
    color: white !important;
}

/* Input field focus states */
.form-control:focus, .form-select:focus {
    border-color: #86b7fe;
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

/* Dark mode input focus */
.dark-mode .form-control:focus, .dark-mode .form-select:focus {
    border-color: #0d6efd;
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.5);
}

/* Canvas text selection handles */
.fabric-text-controls {
    border-color: red !important;
}

/* Footer button spacing */
.footer-buttons {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 10px;
}

/* Modal backdrop */
.modal-backdrop {
    background-color: rgba(0, 0, 0, 0.5);
}

/* Responsive canvas */
@media (max-width: 768px) {
    .canvas-container {
        width: 100% !important;
        max-width: 100%;
        overflow-x: auto;
    }
    
    canvas#canvas {
        max-width: 100%;
        height: auto !important;
    }
}

/* Print styles */
@media print {
    .simple-footer,
    .reply-mode-badge,
    .addons-buttons-container,
    #qso-details-container,
    #my-details-container,
    #my-addons-container {
        display: none !important;
    }
    
    .canvas-container {
        border: none !important;
        box-shadow: none !important;
        margin: 0 !important;
        padding: 0 !important;
    }
    
    body {
        background-color: white !important;
        padding: 0 !important;
        margin: 0 !important;
    }
    
    .simple-footer {
        display: none !important;
    }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .btn, .form-control, .form-select {
        border-width: 2px !important;
    }
    
    .dark-mode .btn, .dark-mode .form-control, .dark-mode .form-select {
        border-color: #fff !important;
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    .reply-mode-badge {
        animation: none !important;
    }
	/* Disabled RST_SENT styling */
#RST_SENT[readonly] {
    cursor: not-allowed;
    opacity: 0.8;
    background-color: #f8f9fa !important;
}

#RST_SENT_DROPDOWN:disabled {
    background-color: #E9ECEF !important;
    cursor: not-allowed;
    opacity: 0.7;
}

.rst-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}
	<style>
    /* === ADDRESS BUTTON ALIGNMENT FIX === */
    #my-addons-container .addons-buttons-container {
        display: flex;
        flex-wrap: wrap;
        align-items: center;
        justify-content: space-between;
        gap: 8px;
        margin: 10px 0;
    }

    /* Container for left-side buttons */
    .addons-left-buttons {
        display: flex;
        flex-wrap: wrap;
        align-items: center;
        gap: 8px;
        flex: 1;
        min-height: 40px; /* Ensure consistent height */
    }

    /* Container for right-side buttons */
    .addons-right-buttons {
        display: flex;
        align-items: center;
        gap: 8px;
    }

    /* Each button group (button + delete button) */
    .addons-left-buttons .button-group {
        display: flex;
        align-items: center;
        gap: 4px;
        height: 38px; /* Fixed height for consistent alignment */
        flex-shrink: 0; /* Prevent wrapping issues */
    }

    /* Make all buttons consistent height */
    .addons-left-buttons .button-group .btn-sm,
    .addons-right-buttons .btn-sm {
        height: 38px;
        display: flex;
        align-items: center;
        justify-content: center;
        flex-shrink: 0; /* Prevent shrinking */
    }

    /* === FIXED FOOTER STYLES === */
    .simple-footer {
        position: fixed;
        bottom: 0;
        left: 0;
        width: 100%;
        padding: 12px 0;
        z-index: 1000;
        transition: all 0.3s ease;
        border-top: none !important;
    }
    
    .footer-content {
        max-width: 1000px;
        margin: 0 auto;
        padding: 0 15px;
    }
    
    .footer-text {
        font-size: 14px;
        font-weight: 500;
        margin-bottom: 8px;
    }
    
    /* Light mode footer */
    .light-mode .simple-footer {
        background-color: #FCFCE6 !important;
        border-top: 1px solid #dee2e6;
        color: #6c757d;
    }
    
    .light-mode .footer-text {
        color: #6c757d;
    }
    
    /* Dark mode footer */
    .dark-mode .simple-footer {
        background-color: #000000 !important;
        border-top: 1px solid #444;
        color: #adb5bd;
    }
    
    .dark-mode .footer-text {
        color: #adb5bd;
    }
    
    /* Adjust body padding to prevent content hiding behind footer */
    body {
        padding-bottom: 140px;
    }
    
    /* For mobile responsiveness */
    @media (max-width: 768px) {
        .footer-text {
            font-size: 12px;
        }
        
        .footer-buttons .btn {
            font-size: 12px;
            padding: 4px 8px;
        }
        
        body {
            padding-bottom: 160px;
        }
        
        .addons-buttons-container {
            flex-direction: column;
            align-items: flex-start !important;
        }
        
        .addons-right-buttons {
            width: 100%;
            justify-content: flex-start;
            margin-top: 10px;
        }
    }
    
    @media (max-width: 576px) {
        .footer-text {
            font-size: 11px;
        }
        
        .footer-content {
            padding: 0 10px;
        }
    }
    
    /* Styling for disabled RST Received elements */
    .rst-rcvd-container input[readonly] {
        background-color: #e9ecef !important;
        color: #6c757d;
        border-color: #ced4da;
    }
    
    .rst-rcvd-container .disabled {
        opacity: 0.6;
        cursor: not-allowed;
    }
    
    .rst-rcvd-container select:disabled {
        background-color: #e9ecef !important;
        color: #6c757d;
        border-color: #ced4da;
        cursor: not-allowed;
    }
    
    /* === ADDRESS TEXT AT BOTTOM OF CANVAS === */
    .address-bottom-text {
        font-family: 'Arial', sans-serif;
        font-size: 14px;
        fill: #FFFF00;
        font-weight: bold;
        text-align: center;
    }
    
    /* === REPLY MODE STYLES === */
    .reply-mode-badge {
        position: fixed;
        top: 10px;
        right: 10px;
        background: #e91e63;
        color: white;
        padding: 8px 15px;
        border-radius: 20px;
        font-size: 14px;
        font-weight: bold;
        z-index: 1001;
        box-shadow: 0 2px 5px rgba(0,0,0,0.2);
    }
    
    .reply-notification {
        margin: 10px auto;
        max-width: 1000px;
    }
    
    .reply-highlight {
        animation: pulse 1s infinite;
        border-color: #e91e63 !important;
    }
    
    @keyframes pulse {
        0% { box-shadow: 0 0 0 0 rgba(233, 30, 99, 0.4); }
        70% { box-shadow: 0 0 0 10px rgba(233, 30, 99, 0); }
        100% { box-shadow: 0 0 0 0 rgba(233, 30, 99, 0); }
    }
</style>
}
