/* CSS Variables */
:root {
    --primary-color: #007AFF;
    --primary-hover: #0056b3;
    --secondary-color: #6c757d;
    --success-color: #28a745;
    --danger-color: #dc3545;
    --warning-color: #ffc107;
    --info-color: #17a2b8;
    --light-color: #f8f9fa;
    --dark-color: #343a40;
    --white: #ffffff;
    --gray-100: #f8f9fa;
    --gray-200: #e9ecef;
    --gray-300: #dee2e6;
    --gray-400: #ced4da;
    --gray-500: #adb5bd;
    --gray-600: #6c757d;
    --gray-700: #495057;
    --gray-800: #343a40;
    --gray-900: #212529;
    --sidebar-width: 260px;
    --header-height: 60px;
    --border-radius: 12px;
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --transition: all 0.3s ease;
}

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    color: var(--gray-800);
}

/* Auth Container Styles */
.auth-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 20px;
}

.auth-form {
    background: var(--white);
    border-radius: var(--border-radius);
    padding: 40px;
    width: 100%;
    max-width: 420px;
    box-shadow: var(--shadow-lg);
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-20px); }
    to { opacity: 1; transform: translateY(0); }
}

.auth-header {
    text-align: center;
    margin-bottom: 30px;
}

.logo-icon {
    font-size: 48px;
    color: var(--primary-color);
    margin-bottom: 16px;
}

.auth-header h1 {
    font-size: 24px;
    color: var(--gray-800);
    margin-bottom: 8px;
}

.auth-header p {
    color: var(--gray-600);
    font-size: 14px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--gray-700);
    font-size: 14px;
}

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-wrapper i {
    position: absolute;
    left: 14px;
    color: var(--gray-500);
    font-size: 16px;
}

.input-wrapper input {
    width: 100%;
    padding: 14px 14px 14px 44px;
    border: 2px solid var(--gray-300);
    border-radius: 8px;
    font-size: 15px;
    transition: var(--transition);
    background: var(--gray-100);
}

.input-wrapper input:focus {
    outline: none;
    border-color: var(--primary-color);
    background: var(--white);
}

.input-wrapper input::placeholder {
    color: var(--gray-500);
}

.auth-footer {
    text-align: center;
    margin-top: 24px;
    padding-top: 24px;
    border-top: 1px solid var(--gray-200);
}

.auth-footer p {
    color: var(--gray-600);
    font-size: 14px;
}

.auth-footer a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
}

.auth-footer a:hover {
    text-decoration: underline;
}

/* Button Styles */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.btn-primary {
    background: var(--primary-color);
    color: var(--white);
}

.btn-primary:hover {
    background: var(--primary-hover);
}

.btn-secondary {
    background: var(--gray-200);
    color: var(--gray-700);
}

.btn-secondary:hover {
    background: var(--gray-300);
}

.btn-full {
    width: 100%;
}

/* Dashboard Container */
.dashboard-container {
    display: flex;
    min-height: 100vh;
    background: var(--gray-100);
}

/* Sidebar Styles */
.sidebar {
    width: var(--sidebar-width);
    background: linear-gradient(180deg, #2c3e50 0%, #1a252f 100%);
    color: var(--white);
    position: fixed;
    height: 100vh;
    display: flex;
    flex-direction: column;
    z-index: 1000;
    transition: var(--transition);
}

.sidebar-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar-header i {
    font-size: 24px;
    color: var(--primary-color);
}

.sidebar-header span {
    font-size: 18px;
    font-weight: 700;
}

.nav-menu {
    list-style: none;
    padding: 16px 0;
    flex: 1;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 24px;
    cursor: pointer;
    transition: var(--transition);
    color: rgba(255, 255, 255, 0.7);
    border-left: 4px solid transparent;
}

.nav-item:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--white);
}

.nav-item.active {
    background: rgba(0, 122, 255, 0.2);
    color: var(--white);
    border-left-color: var(--primary-color);
}

.nav-item i {
    font-size: 18px;
    width: 24px;
    text-align: center;
}

.nav-item span {
    font-size: 15px;
}

.sidebar-footer {
    padding: 16px 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.user-info i {
    font-size: 24px;
    color: var(--gray-400);
}

.user-info span {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.8);
}

.btn-logout {
    background: rgba(220, 53, 69, 0.2);
    border: none;
    color: var(--danger-color);
    width: 36px;
    height: 36px;
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition);
}

.btn-logout:hover {
    background: var(--danger-color);
    color: var(--white);
}

/* Main Content */
.main-content {
    flex: 1;
    margin-left: var(--sidebar-width);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Header */
.header {
    background: var(--white);
    height: var(--header-height);
    display: flex;
    align-items: center;
    padding: 0 24px;
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 100;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 20px;
    color: var(--gray-700);
    cursor: pointer;
    padding: 8px;
    margin-right: 16px;
}

.header h2 {
    flex: 1;
    font-size: 20px;
    color: var(--gray-800);
}

.header-actions {
    color: var(--gray-600);
    font-size: 14px;
}

/* Section Styles */
.section {
    display: none;
    padding: 24px;
    flex: 1;
}

.section.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 24px;
}

.stat-card {
    background: var(--white);
    border-radius: var(--border-radius);
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 20px;
    box-shadow: var(--shadow);
}

.stat-icon {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
}

.stat-icon.incoming {
    background: rgba(0, 122, 255, 0.1);
    color: var(--primary-color);
}

.stat-icon.outgoing {
    background: rgba(40, 167, 69, 0.1);
    color: var(--success-color);
}

.stat-icon.incoming-stat {
    background: rgba(255, 193, 7, 0.1);
    color: var(--warning-color);
}

.stat-icon.duration {
    background: rgba(111, 66, 193, 0.1);
    color: #6f42c1;
}

.stat-info h3 {
    font-size: 28px;
    color: var(--gray-800);
    margin-bottom: 4px;
}

.stat-info p {
    font-size: 14px;
    color: var(--gray-600);
}

/* Dashboard Grid */
.dashboard-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 20px;
}

/* Card Styles */
.card {
    background: var(--white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    overflow: hidden;
}

.card-header {
    padding: 20px;
    border-bottom: 1px solid var(--gray-200);
}

.card-header h3 {
    font-size: 16px;
    color: var(--gray-800);
    display: flex;
    align-items: center;
    gap: 10px;
}

.card-header h3 i {
    color: var(--primary-color);
}

.card-body {
    padding: 20px;
}

/* Recent List */
.recent-list {
    list-style: none;
}

.recent-list li {
    display: flex;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid var(--gray-200);
}

.recent-list li:last-child {
    border-bottom: none;
}

.recent-list .call-icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 12px;
    font-size: 14px;
}

.recent-list .call-icon.incoming {
    background: rgba(40, 167, 69, 0.1);
    color: var(--success-color);
}

.recent-list .call-icon.outgoing {
    background: rgba(0, 122, 255, 0.1);
    color: var(--primary-color);
}

.recent-list .call-info {
    flex: 1;
}

.recent-list .call-info .phone {
    font-weight: 600;
    color: var(--gray-800);
    font-size: 14px;
}

.recent-list .call-info .time {
    font-size: 12px;
    color: var(--gray-500);
}

.recent-list .call-duration {
    font-size: 13px;
    color: var(--gray-600);
}

.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: var(--gray-500);
}

.empty-state i {
    font-size: 48px;
    margin-bottom: 16px;
    color: var(--gray-400);
}

/* Dialer Styles */
.dialer-container {
    max-width: 480px;
    margin: 0 auto;
    width: 100%;
    padding: 0;
}

.dialer-display {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: var(--border-radius);
    padding: 28px 24px;
    margin-bottom: 24px;
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 90px;
    position: relative;
    overflow: hidden;
}

.dialer-display::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, rgba(255,255,255,0.1) 25%, transparent 25%, transparent 50%, rgba(255,255,255,0.1) 50%, rgba(255,255,255,0.1) 75%, transparent 75%, transparent);
    background-size: 20px 20px;
    opacity: 0.3;
    pointer-events: none;
}

.dialer-display input {
    flex: 1;
    font-size: 36px;
    font-weight: 600;
    border: none;
    outline: none;
    text-align: center;
    letter-spacing: 3px;
    background: transparent;
    color: var(--white);
    min-height: 52px;
    position: relative;
    z-index: 1;
    text-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.dialer-display input::placeholder {
    color: rgba(255, 255, 255, 0.6);
    font-size: 20px;
    font-weight: 400;
}

.btn-clear {
    background: rgba(255, 255, 255, 0.2);
    border: 2px solid rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(10px);
    min-width: 48px;
    min-height: 48px;
    border-radius: 50%;
    cursor: pointer;
    color: var(--white);
    font-size: 22px;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    position: relative;
    z-index: 1;
}

.btn-clear:hover {
    background: rgba(255, 255, 255, 0.3);
    border-color: rgba(255, 255, 255, 0.5);
    transform: scale(1.05);
}

.btn-clear:active {
    transform: scale(0.95);
}

.dialer-pad {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    background: var(--white);
    border-radius: var(--border-radius);
    padding: 28px;
    margin-bottom: 24px;
    box-shadow: var(--shadow);
}

.dial-btn {
    width: 100%;
    min-height: 80px;
    aspect-ratio: 1;
    background: linear-gradient(145deg, #ffffff 0%, #f5f7fa 100%);
    border: 2px solid var(--gray-200);
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    position: relative;
    overflow: hidden;
}

.dial-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: var(--primary-color);
    opacity: 0;
    transform: translate(-50%, -50%);
    transition: width 0.3s, height 0.3s, opacity 0.3s;
}

.dial-btn:hover::before {
    width: 100%;
    height: 100%;
    opacity: 0.1;
}

.dial-btn .number {
    font-size: 32px;
    font-weight: 600;
    color: var(--gray-800);
    position: relative;
    z-index: 1;
}

.dial-btn .letters {
    font-size: 11px;
    color: var(--gray-500);
    letter-spacing: 1.5px;
    font-weight: 500;
    text-transform: uppercase;
    position: relative;
    z-index: 1;
}

.dial-btn:hover {
    background: linear-gradient(145deg, #f5f7fa 0%, #e8ecf1 100%);
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 122, 255, 0.15);
}

.dial-btn:active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    transform: scale(0.92);
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
}

.dial-btn:active .number {
    color: var(--white);
}

.dial-btn:active .letters {
    color: rgba(255, 255, 255, 0.8);
}

.dial-btn-zero {
    position: relative;
}

.dialer-actions {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin-bottom: 20px;
}

.btn-backspace,
.btn-copy {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--gray-100);
    border: 2px solid var(--gray-200);
    color: var(--gray-600);
    font-size: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

.btn-backspace:hover,
.btn-copy:hover {
    background: var(--gray-200);
    border-color: var(--gray-400);
    transform: scale(1.05);
}

.btn-backspace:active,
.btn-copy:active {
    transform: scale(0.95);
}

.btn-call {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: linear-gradient(145deg, #28a745 0%, #20c997 100%);
    border: none;
    color: var(--white);
    font-size: 28px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 16px rgba(40, 167, 69, 0.35);
    display: flex;
    align-items: center;
    justify-content: center;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    position: relative;
    overflow: hidden;
}

.btn-call::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.3s, height 0.3s;
}

.btn-call:hover::before {
    width: 120%;
    height: 120%;
}

.btn-call:hover {
    transform: scale(1.08);
    box-shadow: 0 6px 24px rgba(40, 167, 69, 0.45);
}

.btn-call:active {
    transform: scale(0.95);
    box-shadow: 0 2px 8px rgba(40, 167, 69, 0.3);
}

.dialer-note {
    text-align: center;
    margin-top: 16px;
    font-size: 13px;
    color: var(--gray-500);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 20px;
    background: var(--gray-100);
    border-radius: 8px;
    font-weight: 500;
}

.dialer-note i {
    color: var(--info-color);
}

/* Section Header */
.section-header {
    margin-bottom: 20px;
}

.filters {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.filters select,
.filters input {
    padding: 10px 16px;
    border: 2px solid var(--gray-300);
    border-radius: 8px;
    font-size: 14px;
    background: var(--white);
    transition: var(--transition);
}

.filters select:focus,
.filters input:focus {
    outline: none;
    border-color: var(--primary-color);
}

/* Table Styles */
.table-responsive {
    overflow-x: auto;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th,
.data-table td {
    padding: 14px 16px;
    text-align: left;
    border-bottom: 1px solid var(--gray-200);
}

.data-table th {
    background: var(--gray-100);
    font-weight: 600;
    font-size: 13px;
    color: var(--gray-700);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.data-table td {
    font-size: 14px;
    color: var(--gray-700);
}

.data-table tr:hover {
    background: var(--gray-100);
}

.data-table .call-type {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

.data-table .call-type.incoming {
    background: rgba(40, 167, 69, 0.1);
    color: var(--success-color);
}

.data-table .call-type.outgoing {
    background: rgba(0, 122, 255, 0.1);
    color: var(--primary-color);
}

.data-table .btn-play {
    background: var(--primary-color);
    color: var(--white);
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 13px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: var(--transition);
}

.data-table .btn-play:hover {
    background: var(--primary-hover);
}

.data-table .btn-play:disabled {
    background: var(--gray-400);
    cursor: not-allowed;
}

.empty-row td {
    text-align: center;
    padding: 40px;
    color: var(--gray-500);
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 20px;
}

.pagination button {
    width: 36px;
    height: 36px;
    border: 2px solid var(--gray-300);
    background: var(--white);
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    color: var(--gray-700);
    transition: var(--transition);
}

.pagination button:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.pagination button.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: var(--white);
}

/* Recordings Grid */
.recordings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.recording-card {
    background: var(--white);
    border-radius: var(--border-radius);
    padding: 20px;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.recording-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.recording-card .recording-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.recording-card .recording-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: rgba(0, 122, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    font-size: 20px;
}

.recording-card .recording-title {
    flex: 1;
}

.recording-card .recording-title h4 {
    font-size: 15px;
    color: var(--gray-800);
    margin-bottom: 4px;
}

.recording-card .recording-title p {
    font-size: 13px;
    color: var(--gray-500);
}

.recording-card .recording-meta {
    display: flex;
    justify-content: space-between;
    margin-bottom: 16px;
    font-size: 13px;
    color: var(--gray-600);
}

.recording-card .recording-actions {
    display: flex;
    gap: 8px;
}

.recording-card .btn-sm {
    flex: 1;
    padding: 10px;
    font-size: 13px;
}

/* Modal Styles */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    padding: 20px;
}

.modal-content {
    background: var(--white);
    border-radius: var(--border-radius);
    width: 100%;
    max-width: 480px;
    position: relative;
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: var(--gray-200);
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    cursor: pointer;
    color: var(--gray-600);
    transition: var(--transition);
}

.modal-close:hover {
    background: var(--gray-300);
}

.audio-player {
    padding: 32px;
}

.player-header {
    text-align: center;
    margin-bottom: 24px;
}

.player-header h3 {
    font-size: 18px;
    color: var(--gray-800);
    margin-bottom: 8px;
}

.player-header p {
    font-size: 14px;
    color: var(--gray-500);
}

.player-controls {
    margin-bottom: 24px;
}

.player-controls audio {
    width: 100%;
    border-radius: 8px;
}

.player-actions {
    display: flex;
    justify-content: center;
}

/* Toast Notification */
.toast {
    position: fixed;
    bottom: 24px;
    right: 24px;
    background: var(--gray-800);
    color: var(--white);
    padding: 16px 24px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: var(--shadow-lg);
    z-index: 3000;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from { opacity: 0; transform: translateX(50px); }
    to { opacity: 1; transform: translateX(0); }
}

.toast.success {
    background: var(--success-color);
}

.toast.error {
    background: var(--danger-color);
}

/* Utility Classes */
.hidden {
    display: none !important;
}

/* Responsive Styles */
@media (max-width: 1200px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
    }
    
    .sidebar.open {
        transform: translateX(0);
    }
    
    .main-content {
        margin-left: 0;
    }
    
    .menu-toggle {
        display: block;
    }
    
    .stats-grid {
        grid-template-columns: 1fr 1fr;
        gap: 12px;
    }
    
    .stat-card {
        padding: 16px;
    }
    
    .stat-icon {
        width: 44px;
        height: 44px;
        font-size: 18px;
    }
    
    .stat-info h3 {
        font-size: 20px;
    }
    
    .section {
        padding: 16px;
    }
    
    .filters {
        flex-direction: column;
    }
    
    .filters select,
    .filters input {
        width: 100%;
    }
    
    .recordings-grid {
        grid-template-columns: 1fr;
    }
    
    /* Mobile Dialer Improvements */
    .dialer-container {
        max-width: 100%;
        padding: 0;
    }
    
    .dialer-display {
        padding: 20px 16px;
        margin-bottom: 16px;
        min-height: 76px;
    }
    
    .dialer-display input {
        font-size: 28px;
        min-height: 40px;
        letter-spacing: 2px;
    }
    
    .dialer-display input::placeholder {
        font-size: 16px;
    }
    
    .btn-clear {
        min-width: 40px;
        min-height: 40px;
        font-size: 18px;
    }
    
    .dialer-pad {
        padding: 20px 16px;
        gap: 14px;
        margin-bottom: 16px;
    }
    
    .dial-btn {
        min-height: 68px;
    }
    
    .dial-btn .number {
        font-size: 28px;
    }
    
    .dial-btn .letters {
        font-size: 10px;
    }
    
    .dialer-actions {
        gap: 16px;
    }
    
    .btn-call {
        width: 64px;
        height: 64px;
        font-size: 24px;
    }
    
    .btn-backspace,
    .btn-copy {
        width: 50px;
        height: 50px;
        font-size: 18px;
    }
    
    .dialer-note {
        font-size: 12px;
        padding: 10px 16px;
    }
    
    .dial-btn {
        min-height: 68px;
        font-size: 26px;
    }
    
    .dial-btn span {
        font-size: 10px;
    }
    
    .btn-call {
        width: 68px;
        height: 68px;
        font-size: 26px;
    }
}

@media (max-width: 480px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .auth-form {
        padding: 24px;
    }
    
    /* Small Mobile Dialer Optimizations */
    .dialer-container {
        max-width: 100%;
        padding: 0;
    }
    
    .dialer-display {
        padding: 16px 12px;
        margin-bottom: 12px;
        min-height: 68px;
        border-radius: 10px;
    }
    
    .dialer-display input {
        font-size: 24px;
        letter-spacing: 1px;
    }
    
    .dialer-display input::placeholder {
        font-size: 14px;
    }
    
    .btn-clear {
        min-width: 40px;
        min-height: 40px;
        font-size: 18px;
    }
    
    .dialer-pad {
        padding: 16px;
        gap: 12px;
        margin-bottom: 12px;
        border-radius: 10px;
    }
    
    .dial-btn {
        min-height: 64px;
        font-size: 24px;
        border-width: 1px;
    }
    
    .dial-btn span {
        font-size: 9px;
        margin-top: 1px;
    }
    
    .dialer-actions {
        margin-bottom: 12px;
    }
    
    .btn-call {
        width: 64px;
        height: 64px;
        font-size: 24px;
    }
    
    .dialer-note {
        font-size: 12px;
        padding: 0 12px;
    }
}

/* Extra small devices (very small phones) */
@media (max-width: 360px) {
    .dialer-display {
        padding: 14px 10px;
        min-height: 64px;
    }
    
    .dialer-display input {
        font-size: 20px;
    }
    
    .dialer-pad {
        padding: 12px;
        gap: 10px;
    }
    
    .dial-btn {
        min-height: 56px;
        font-size: 22px;
    }
    
    .dial-btn span {
        font-size: 8px;
    }
    
    .btn-call {
        width: 60px;
        height: 60px;
        font-size: 22px;
    }
    
    .btn-clear {
        min-width: 36px;
        min-height: 36px;
        font-size: 16px;
    }
}

/* Chart Container */
#calls-chart {
    max-height: 250px;
}

/* ===================================
   Developer Logger Styles
   =================================== */

/* Floating Button */
.dev-logger-btn {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    border: none;
    color: white;
    font-size: 22px;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.4);
    z-index: 9999;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.dev-logger-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.5);
}

.dev-logger-btn:active {
    transform: scale(0.95);
}

.log-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    background: var(--danger-color);
    color: white;
    font-size: 11px;
    font-weight: 600;
    min-width: 20px;
    height: 20px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 6px;
}

/* Logger Modal */
.dev-logger-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 10000;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding: 20px;
    animation: fadeIn 0.2s ease;
}

.dev-logger-container {
    background: #1e1e2e;
    border-radius: 16px 16px 0 0;
    width: 100%;
    max-width: 900px;
    height: 80vh;
    max-height: 700px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.3);
    animation: slideUp 0.3s ease;
}

/* Logger Header */
.dev-logger-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    background: #2a2a3e;
    border-bottom: 1px solid #3a3a4e;
}

.dev-logger-header h3 {
    color: #e4e4e7;
    font-size: 16px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
}

.dev-logger-header h3 i {
    color: #8b5cf6;
}

.dev-logger-actions {
    display: flex;
    gap: 8px;
}

.dev-btn {
    background: #3a3a4e;
    border: none;
    color: #a1a1aa;
    width: 36px;
    height: 36px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.dev-btn:hover {
    background: #4a4a5e;
    color: #e4e4e7;
}

/* Logger Tabs */
.dev-logger-tabs {
    display: flex;
    padding: 0 16px;
    background: #252535;
    border-bottom: 1px solid #3a3a4e;
}

.dev-tab {
    background: transparent;
    border: none;
    color: #71717a;
    padding: 14px 20px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    border-bottom: 2px solid transparent;
    transition: all 0.2s ease;
}

.dev-tab:hover {
    color: #a1a1aa;
    background: rgba(255, 255, 255, 0.02);
}

.dev-tab.active {
    color: #8b5cf6;
    border-bottom-color: #8b5cf6;
}

.tab-badge {
    background: #3a3a4e;
    color: #a1a1aa;
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 10px;
    font-weight: 600;
}

.tab-badge.error-badge {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
}

/* Logger Filters */
.dev-logger-filters {
    display: flex;
    gap: 12px;
    padding: 12px 16px;
    background: #252535;
    border-bottom: 1px solid #3a3a4e;
}

.dev-logger-filters input,
.dev-logger-filters select {
    background: #1e1e2e;
    border: 1px solid #3a3a4e;
    color: #e4e4e7;
    padding: 10px 14px;
    border-radius: 8px;
    font-size: 13px;
    transition: all 0.2s ease;
}

.dev-logger-filters input {
    flex: 1;
}

.dev-logger-filters input:focus,
.dev-logger-filters select:focus {
    outline: none;
    border-color: #8b5cf6;
}

.dev-logger-filters input::placeholder {
    color: #52525b;
}

.dev-logger-filters select {
    min-width: 130px;
    cursor: pointer;
}

/* Logger Content */
.dev-logger-content {
    flex: 1;
    overflow: hidden;
    position: relative;
}

.log-panel {
    display: none;
    height: 100%;
}

.log-panel.active {
    display: block;
}

.log-list {
    height: 100%;
    overflow-y: auto;
    padding: 12px 16px;
}

.log-list::-webkit-scrollbar {
    width: 8px;
}

.log-list::-webkit-scrollbar-track {
    background: #1e1e2e;
}

.log-list::-webkit-scrollbar-thumb {
    background: #3a3a4e;
    border-radius: 4px;
}

.log-list::-webkit-scrollbar-thumb:hover {
    background: #4a4a5e;
}

.log-empty {
    color: #52525b;
    text-align: center;
    padding: 40px;
    font-size: 14px;
}

/* Log Item */
.log-item {
    background: #252535;
    border-radius: 8px;
    padding: 12px 14px;
    margin-bottom: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    border-left: 3px solid transparent;
}

.log-item:hover {
    background: #2a2a3e;
}

.log-item.log-log {
    border-left-color: #6b7280;
}

.log-item.log-info {
    border-left-color: #3b82f6;
}

.log-item.log-warn {
    border-left-color: #f59e0b;
}

.log-item.log-error {
    border-left-color: #ef4444;
}

.log-item.log-debug {
    border-left-color: #8b5cf6;
}

.log-item.network-success {
    border-left-color: #22c55e;
}

.log-item.network-error {
    border-left-color: #ef4444;
}

.log-item.network-pending {
    border-left-color: #f59e0b;
}

.log-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 6px;
    flex-wrap: wrap;
}

.log-level {
    font-size: 10px;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 4px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.log-level.log {
    background: rgba(107, 114, 128, 0.2);
    color: #9ca3af;
}

.log-level.info {
    background: rgba(59, 130, 246, 0.2);
    color: #60a5fa;
}

.log-level.warn {
    background: rgba(245, 158, 11, 0.2);
    color: #fbbf24;
}

.log-level.error {
    background: rgba(239, 68, 68, 0.2);
    color: #f87171;
}

.log-level.debug {
    background: rgba(139, 92, 246, 0.2);
    color: #a78bfa;
}

.log-method {
    font-size: 11px;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 4px;
    background: rgba(99, 102, 241, 0.2);
    color: #818cf8;
}

.log-method.GET {
    background: rgba(34, 197, 94, 0.2);
    color: #4ade80;
}

.log-method.POST {
    background: rgba(59, 130, 246, 0.2);
    color: #60a5fa;
}

.log-method.PUT {
    background: rgba(245, 158, 11, 0.2);
    color: #fbbf24;
}

.log-method.DELETE {
    background: rgba(239, 68, 68, 0.2);
    color: #f87171;
}

.log-status {
    font-size: 11px;
    font-weight: 600;
    padding: 3px 8px;
    border-radius: 4px;
}

.log-status.status-success {
    background: rgba(34, 197, 94, 0.2);
    color: #4ade80;
}

.log-status.status-error {
    background: rgba(239, 68, 68, 0.2);
    color: #f87171;
}

.log-status.status-pending {
    background: rgba(245, 158, 11, 0.2);
    color: #fbbf24;
}

.log-duration {
    font-size: 11px;
    color: #71717a;
}

.log-time {
    font-size: 11px;
    color: #52525b;
    margin-left: auto;
}

.log-type {
    font-size: 10px;
    font-weight: 600;
    padding: 3px 8px;
    border-radius: 4px;
    background: rgba(239, 68, 68, 0.2);
    color: #f87171;
    text-transform: uppercase;
}

.log-message {
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 13px;
    color: #e4e4e7;
    word-break: break-word;
    white-space: pre-wrap;
    line-height: 1.5;
}

.log-url {
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 12px;
    color: #a1a1aa;
    word-break: break-all;
}

.log-details {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid #3a3a4e;
}

.log-details pre {
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 11px;
    color: #a1a1aa;
    white-space: pre-wrap;
    word-break: break-word;
    background: #1e1e2e;
    padding: 10px;
    border-radius: 6px;
    max-height: 200px;
    overflow-y: auto;
    margin: 0;
}

.detail-section {
    margin-bottom: 12px;
}

.detail-section strong {
    display: block;
    color: #71717a;
    font-size: 11px;
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.detail-section.error {
    color: #f87171;
}

/* Logger Footer */
.dev-logger-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    background: #252535;
    border-top: 1px solid #3a3a4e;
}

#log-status {
    font-size: 12px;
    color: #52525b;
}

.dev-toggle {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #71717a;
    font-size: 12px;
    cursor: pointer;
}

.dev-toggle input {
    cursor: pointer;
}

/* Responsive Styles for Dev Logger */
@media (max-width: 768px) {
    .dev-logger-btn {
        bottom: 16px;
        right: 16px;
        width: 50px;
        height: 50px;
        font-size: 20px;
    }

    .dev-logger-modal {
        padding: 0;
    }

    .dev-logger-container {
        border-radius: 16px 16px 0 0;
        height: 85vh;
        max-height: none;
    }

    .dev-logger-header {
        padding: 14px 16px;
    }

    .dev-logger-tabs {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .dev-tab {
        padding: 12px 16px;
        font-size: 13px;
        white-space: nowrap;
    }

    .dev-logger-filters {
        flex-direction: column;
        gap: 8px;
    }

    .dev-logger-filters select {
        min-width: 100%;
    }

    .log-header {
        gap: 6px;
    }

    .log-time {
        width: 100%;
        margin-left: 0;
        margin-top: 4px;
    }
}

@media (max-width: 480px) {
    .dev-logger-btn {
        bottom: 12px;
        right: 12px;
        width: 46px;
        height: 46px;
        font-size: 18px;
    }

    .dev-logger-header h3 {
        font-size: 14px;
    }

    .dev-btn {
        width: 32px;
        height: 32px;
    }

    .log-message {
        font-size: 12px;
    }
}

/* ===================================
   Settings Page Styles
   =================================== */

.settings-container {
    max-width: 600px;
    margin: 0 auto;
}

.settings-card {
    background: var(--white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    margin-bottom: 20px;
    overflow: hidden;
}

.settings-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 20px;
    background: var(--gray-100);
    border-bottom: 1px solid var(--gray-200);
}

.settings-header i {
    font-size: 20px;
    color: var(--primary-color);
}

.settings-header h3 {
    font-size: 16px;
    font-weight: 600;
    color: var(--gray-800);
    margin: 0;
}

.settings-body {
    padding: 0;
}

.setting-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid var(--gray-200);
}

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

.setting-info {
    flex: 1;
    padding-right: 16px;
}

.setting-label {
    display: block;
    font-size: 15px;
    font-weight: 500;
    color: var(--gray-800);
    margin-bottom: 4px;
}

.setting-description {
    display: block;
    font-size: 13px;
    color: var(--gray-500);
    line-height: 1.4;
}

/* Toggle Switch */
.toggle-switch {
    position: relative;
    display: inline-block;
    width: 52px;
    height: 28px;
    flex-shrink: 0;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--gray-300);
    border-radius: 28px;
    transition: all 0.3s ease;
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 22px;
    width: 22px;
    left: 3px;
    bottom: 3px;
    background-color: var(--white);
    border-radius: 50%;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.toggle-switch input:checked + .toggle-slider {
    background-color: var(--success-color);
}

.toggle-switch input:checked + .toggle-slider:before {
    transform: translateX(24px);
}

.toggle-switch input:focus + .toggle-slider {
    box-shadow: 0 0 0 3px rgba(40, 167, 69, 0.2);
}

/* About Info */
.about-info {
    padding: 20px;
    text-align: center;
}

.about-info p {
    margin: 8px 0;
    font-size: 14px;
    color: var(--gray-600);
}

.about-info p strong {
    color: var(--gray-800);
}

/* Settings Responsive */
@media (max-width: 480px) {
    .settings-container {
        max-width: 100%;
    }
    
    .settings-card {
        border-radius: 10px;
        margin-bottom: 16px;
    }
    
    .settings-header {
        padding: 16px;
    }
    
    .settings-header i {
        font-size: 18px;
    }
    
    .settings-header h3 {
        font-size: 15px;
    }
    
    .setting-item {
        padding: 14px 16px;
    }
    
    .setting-label {
        font-size: 14px;
    }
    
    .setting-description {
        font-size: 12px;
    }
    
    .toggle-switch {
        width: 48px;
        height: 26px;
    }
    
    .toggle-slider:before {
        height: 20px;
        width: 20px;
    }
    
    .toggle-switch input:checked + .toggle-slider:before {
        transform: translateX(22px);
    }
    
    /* Mobile table improvements */
    .data-table th,
    .data-table td {
        padding: 10px 8px;
        font-size: 12px;
    }
    
    .data-table .call-type {
        padding: 3px 6px;
        font-size: 10px;
    }
    
    .data-table .btn-play {
        padding: 6px 10px;
        font-size: 11px;
    }
    
    /* Hide less important columns on mobile */
    .data-table th:nth-child(3),
    .data-table td:nth-child(3) {
        display: none;
    }
}

/* ===================================
   Additional Responsive Improvements
   =================================== */

/* Mobile-first card improvements */
@media (max-width: 600px) {
    .recording-card {
        padding: 16px;
    }
    
    .recording-card .recording-icon {
        width: 42px;
        height: 42px;
        font-size: 18px;
    }
    
    .recording-card .recording-title h4 {
        font-size: 14px;
    }
    
    .recording-card .recording-meta {
        flex-direction: column;
        gap: 4px;
    }
    
    .recording-card .recording-actions {
        flex-direction: column;
    }
    
    /* Improve modal on mobile */
    .modal {
        padding: 16px;
        align-items: flex-end;
    }
    
    .modal-content {
        max-width: 100%;
        border-radius: 16px 16px 0 0;
    }
    
    .audio-player {
        padding: 24px 20px;
    }
    
    .player-header h3 {
        font-size: 16px;
    }
    
    .player-header p {
        font-size: 12px;
    }
    
    /* History table mobile view */
    .table-responsive {
        margin: 0 -16px;
        padding: 0 16px;
    }
    
    .data-table {
        min-width: 500px;
    }
}

/* ====================================
   CALL HISTORY TABLE RESPONSIVE STYLES
   ==================================== */

/* Table base improvements */
.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}

.data-table thead {
    background: linear-gradient(135deg, var(--gray-100), var(--gray-50));
}

.data-table th {
    padding: 16px 14px;
    text-align: left;
    font-weight: 600;
    color: var(--gray-700);
    border-bottom: 2px solid var(--gray-200);
    white-space: nowrap;
    text-transform: uppercase;
    font-size: 11px;
    letter-spacing: 0.5px;
}

.data-table td {
    padding: 16px 14px;
    border-bottom: 1px solid var(--gray-200);
    vertical-align: middle;
}

.data-table tr {
    transition: all 0.2s ease;
}

.data-table tbody tr:hover {
    background: linear-gradient(90deg, rgba(0, 122, 255, 0.04), transparent);
    transform: translateX(2px);
}

/* Call type badge */
.call-type {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    border-radius: 24px;
    font-size: 12px;
    font-weight: 600;
    text-transform: capitalize;
}

.call-type.incoming {
    background: linear-gradient(135deg, rgba(40, 167, 69, 0.15), rgba(40, 167, 69, 0.08));
    color: #1e7e34;
    border: 1px solid rgba(40, 167, 69, 0.2);
}

.call-type.outgoing {
    background: linear-gradient(135deg, rgba(0, 122, 255, 0.15), rgba(0, 122, 255, 0.08));
    color: #0056b3;
    border: 1px solid rgba(0, 122, 255, 0.2);
}

.call-type.missed {
    background: linear-gradient(135deg, rgba(220, 53, 69, 0.15), rgba(220, 53, 69, 0.08));
    color: #bd2130;
    border: 1px solid rgba(220, 53, 69, 0.2);
}

.call-type.unknown {
    background: linear-gradient(135deg, rgba(108, 117, 125, 0.15), rgba(108, 117, 125, 0.08));
    color: #545b62;
    border: 1px solid rgba(108, 117, 125, 0.2);
}

/* Play button */
.btn-play {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 18px;
    background: linear-gradient(135deg, var(--primary-color), #0056b3);
    color: white;
    border: none;
    border-radius: 24px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 122, 255, 0.3);
}

.btn-play:hover {
    background: linear-gradient(135deg, #0056b3, var(--primary-color));
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 122, 255, 0.4);
}

.btn-play:active {
    transform: translateY(0);
}

.no-recording {
    color: var(--gray-400);
    font-size: 13px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    background: var(--gray-50);
    border-radius: 20px;
}

/* ====================================
   MOBILE CALL HISTORY CARDS
   ==================================== */
@media (max-width: 768px) {
    .data-table {
        display: block;
        min-width: unset !important;
    }
    
    .data-table thead {
        display: none;
    }
    
    .data-table tbody {
        display: flex;
        flex-direction: column;
        gap: 12px;
    }
    
    .data-table tr {
        display: flex;
        flex-direction: column;
        background: white;
        border-radius: 16px;
        padding: 0;
        box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
        border: 1px solid var(--gray-200);
        overflow: hidden;
        margin-bottom: 0;
    }
    
    .data-table tbody tr:hover {
        transform: translateY(-2px);
        box-shadow: 0 4px 20px rgba(0, 0, 0, 0.12);
    }
    
    .data-table td {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 14px 18px;
        border-bottom: 1px solid var(--gray-100);
        text-align: right;
    }
    
    .data-table td:first-child {
        background: linear-gradient(135deg, var(--gray-50), white);
        padding: 16px 18px;
    }
    
    .data-table td:last-child {
        border-bottom: none;
        padding: 18px;
        background: var(--gray-50);
        justify-content: center;
    }
    
    .data-table td::before {
        content: attr(data-label);
        font-weight: 700;
        color: var(--gray-600);
        text-align: left;
        flex-shrink: 0;
        margin-right: 16px;
        font-size: 12px;
        text-transform: uppercase;
        letter-spacing: 0.5px;
    }
    
    .data-table td:first-child::before,
    .data-table td:last-child::before {
        content: none;
    }
    
    .data-table td:first-child {
        justify-content: center;
    }
    
    .data-table .hide-mobile,
    .data-table td.hide-mobile {
        display: none !important;
    }
    
    .call-type {
        padding: 8px 16px;
        font-size: 13px;
    }
    
    .call-type i {
        font-size: 14px;
    }
    
    .btn-play {
        padding: 14px 28px;
        font-size: 15px;
        width: 100%;
        justify-content: center;
        border-radius: 10px;
    }
    
    .no-recording {
        justify-content: center;
        width: 100%;
        padding: 14px;
    }
    
    .empty-row td {
        text-align: center !important;
        justify-content: center;
        padding: 40px 20px;
    }
    
    .empty-row td::before {
        content: none !important;
    }
    
    /* Table responsive container */
    .table-responsive {
        overflow: visible;
        margin: 0 -8px;
        padding: 0 8px;
    }
}

/* Extra small devices */
@media (max-width: 480px) {
    .data-table td {
        padding: 12px 14px;
        font-size: 13px;
    }
    
    .data-table td::before {
        font-size: 11px;
    }
    
    .call-type {
        padding: 6px 12px;
        font-size: 12px;
    }
}

/* Additional table element styles */
.phone-number {
    font-weight: 600;
    color: var(--gray-800);
    font-size: 14px;
}

.contact-name {
    color: var(--gray-600);
}

.duration-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    background: var(--gray-100);
    border-radius: 16px;
    font-size: 13px;
    color: var(--gray-700);
    font-weight: 500;
}

.duration-badge i {
    font-size: 11px;
    color: var(--gray-500);
}

.date-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.date-relative {
    color: var(--gray-600);
    font-size: 13px;
}

.empty-state-inline {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 40px 20px;
    color: var(--gray-400);
}

.empty-state-inline i {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.5;
}

.empty-state-inline p {
    font-size: 16px;
    margin: 0;
}

@media (max-width: 768px) {
    .phone-number {
        font-size: 15px;
    }
    
    .duration-badge {
        background: linear-gradient(135deg, var(--gray-100), var(--gray-50));
    }
}

/* Filters responsive */
.filters {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 20px;
}

.filters select,
.filters input {
    padding: 10px 14px;
    border: 1px solid var(--gray-300);
    border-radius: 8px;
    font-size: 14px;
    background: white;
    min-width: 140px;
}

.filters input[type="text"] {
    flex: 1;
    min-width: 200px;
}

@media (max-width: 576px) {
    .filters {
        flex-direction: column;
    }
    
    .filters select,
    .filters input {
        width: 100%;
        min-width: unset;
    }
}

/* Section header */
.section-header {
    margin-bottom: 20px;
}

/* Table container */
.table-responsive {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

@media (max-width: 768px) {
    .table-responsive {
        overflow: visible;
    }
}

/* Pagination improvements */
.pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 20px;
    flex-wrap: wrap;
}

.pagination button {
    padding: 8px 14px;
    border: 1px solid var(--gray-300);
    background: white;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    transition: var(--transition);
}

.pagination button:hover {
    background: var(--gray-100);
}

.pagination button.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

/* Recording cards improvements */
.recordings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

.recording-card {
    background: white;
    border-radius: 12px;
    padding: 20px;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.recording-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.recording-header {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    margin-bottom: 16px;
}

.recording-icon {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, var(--primary-color), #764ba2);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 20px;
    flex-shrink: 0;
}

.recording-title {
    flex: 1;
    min-width: 0;
}

.recording-title h4 {
    font-size: 16px;
    font-weight: 600;
    color: var(--gray-800);
    margin-bottom: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.recording-title p {
    font-size: 13px;
    color: var(--gray-500);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.recording-meta {
    display: flex;
    gap: 16px;
    margin-bottom: 16px;
    font-size: 13px;
    color: var(--gray-600);
}

.recording-meta span {
    display: flex;
    align-items: center;
    gap: 6px;
}

.recording-actions {
    display: flex;
    gap: 10px;
}

.recording-actions .btn {
    flex: 1;
    padding: 10px;
    font-size: 13px;
}

.btn-sm {
    padding: 8px 12px;
    font-size: 13px;
}

@media (max-width: 576px) {
    .recordings-grid {
        grid-template-columns: 1fr;
    }
    
    .recording-card {
        padding: 16px;
    }
}

/* Empty state improvements */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--gray-500);
}

.empty-state i {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.5;
}

.empty-state p {
    font-size: 16px;
}

/* Tablet improvements */
@media (min-width: 769px) and (max-width: 1024px) {
    .sidebar {
        width: 220px;
    }
    
    .main-content {
        margin-left: 220px;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
    
    .recordings-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Large screen improvements */
@media (min-width: 1400px) {
    .stats-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 24px;
    }
    
    .dashboard-grid {
        grid-template-columns: 2fr 1fr;
        gap: 24px;
    }
    
    .recordings-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 24px;
    }
    
    .section {
        padding: 32px;
    }
}

/* Disable text selection on interactive elements for mobile */
.dial-btn,
.btn-call,
.btn-clear,
.nav-item,
.toggle-switch {
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

/* Improve touch scrolling */
.main-content,
.section,
.log-list,
.table-responsive {
    -webkit-overflow-scrolling: touch;
}

/* Prevent pull-to-refresh on mobile */
html, body {
    overscroll-behavior: none;
}

/* Fix for iOS safe areas */
@supports (padding: env(safe-area-inset-bottom)) {
    .sidebar-footer {
        padding-bottom: calc(16px + env(safe-area-inset-bottom));
    }
    
    .dev-logger-btn {
        bottom: calc(24px + env(safe-area-inset-bottom));
    }
    
    .toast {
        bottom: calc(24px + env(safe-area-inset-bottom));
    }
}

/* Extra responsive fixes for very small screens */
@media (max-width: 360px) {
    .section {
        padding: 12px;
    }
    
    .card-header {
        padding: 14px;
    }
    
    .card-body {
        padding: 14px;
    }
    
    .stat-card {
        padding: 12px;
        gap: 12px;
    }
    
    .stat-icon {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }
    
    .stat-info h3 {
        font-size: 18px;
    }
    
    .stat-info p {
        font-size: 12px;
    }
    
    .header h2 {
        font-size: 16px;
    }
    
    .setting-info {
        padding-right: 12px;
    }
}

/* DevTools button hidden state */
.dev-logger-btn.hidden {
    display: none !important;
}

/* ========== Server URL Settings Styles ========== */
.url-input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--gray-200);
    border-radius: 8px;
    font-size: 14px;
    transition: border-color 0.2s, box-shadow 0.2s;
    background: var(--gray-100);
}

.url-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(0, 122, 255, 0.15);
    background: white;
}

.url-input::placeholder {
    color: var(--gray-400);
}

.btn-sm {
    padding: 8px 14px;
    font-size: 13px;
    border-radius: 6px;
}

.btn-outline {
    background: transparent;
    border: 1px solid var(--gray-300);
    color: var(--gray-600);
    cursor: pointer;
    transition: all 0.2s;
}

.btn-outline:hover {
    background: var(--gray-100);
    border-color: var(--primary);
    color: var(--primary);
}

.server-status {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 13px;
}

.server-status.testing {
    background: #fff3cd;
    color: #856404;
}

.server-status.success {
    background: #d4edda;
    color: #155724;
}

.server-status.error {
    background: #f8d7da;
    color: #721c24;
}

.server-status .status-indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    animation: pulse 1.5s infinite;
}

.server-status.testing .status-indicator {
    background: #ffc107;
}

.server-status.success .status-indicator {
    background: #28a745;
    animation: none;
}

.server-status.error .status-indicator {
    background: #dc3545;
    animation: none;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.preset-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.url-input-container {
    width: 100%;
}

/* Mobile responsive for server settings */
@media (max-width: 576px) {
    .url-actions {
        flex-direction: column;
    }
    
    .url-actions .btn {
        width: 100%;
        justify-content: center;
    }
    
    .preset-buttons {
        flex-direction: column;
    }
    
    .preset-buttons .btn {
        width: 100%;
    }
}
