/* Audiobook Speed Calculator Styles */
.asc-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: white;
    position: relative;
    overflow: hidden;
}

@media (min-width: 768px) {
    .asc-container {
        padding: 2rem 1rem;
    }
}

/* Animated Background Elements */
.asc-container::before {
    content: '';
    position: absolute;
    top: -10rem;
    right: -10rem;
    width: 20rem;
    height: 20rem;
    background: linear-gradient(135deg, rgba(168, 85, 247, 0.1), rgba(59, 130, 246, 0.1));
    border-radius: 50%;
    filter: blur(40px);
    animation: float 6s ease-in-out infinite;
    z-index: 0;
}

.asc-container::after {
    content: '';
    position: absolute;
    bottom: -10rem;
    left: -10rem;
    width: 20rem;
    height: 20rem;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(16, 185, 129, 0.1));
    border-radius: 50%;
    filter: blur(40px);
    animation: float 6s ease-in-out infinite reverse;
    z-index: 0;
}

@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(180deg); }
}

/* All content above background */
.asc-container > * {
    position: relative;
    z-index: 1;
}

/* Header Styles */
.asc-header {
    text-align: center;
    margin-bottom: 2rem;
}

@media (min-width: 768px) {
    .asc-header {
        margin-bottom: 4rem;
    }
}

.asc-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 4rem;
    height: 4rem;
    background: linear-gradient(135deg, #8b5cf6, #3b82f6);
    color: white;
    border-radius: 1rem;
    margin-bottom: 1rem;
    font-size: 1.5rem;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

@media (min-width: 768px) {
    .asc-icon {
        width: 5rem;
        height: 5rem;
        margin-bottom: 1.5rem;
        font-size: 2rem;
    }
}

.asc-icon:hover {
    transform: scale(1.1);
}

.asc-title {
    font-size: 2rem;
    font-weight: 900;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, #8b5cf6, #ec4899, #3b82f6);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1.2;
}

@media (min-width: 640px) {
    .asc-title {
        font-size: 2.5rem;
    }
}

@media (min-width: 768px) {
    .asc-title {
        font-size: 3rem;
    }
}

@media (min-width: 1024px) {
    .asc-title {
        font-size: 3.5rem;
    }
}

.asc-description {
    font-size: 1rem;
    color: #6b7280;
    max-width: 48rem;
    margin: 0 auto 1.5rem;
    line-height: 1.6;
    padding: 0 1rem;
}

@media (min-width: 768px) {
    .asc-description {
        font-size: 1.125rem;
        margin-bottom: 2rem;
        padding: 0;
    }
}

@media (min-width: 1024px) {
    .asc-description {
        font-size: 1.25rem;
    }
}

.asc-features {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

@media (min-width: 768px) {
    .asc-features {
        gap: 2rem;
    }
}

.asc-feature {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #8b5cf6;
    font-weight: 600;
    font-size: 0.875rem;
}

@media (min-width: 768px) {
    .asc-feature {
        font-size: 1rem;
    }
}

.asc-feature i {
    font-size: 1rem;
}

@media (min-width: 768px) {
    .asc-feature i {
        font-size: 1.25rem;
    }
}

/* Navigation Tabs */
.asc-tabs {
    display: flex;
    justify-content: center;
    margin-bottom: 2rem;
}

.asc-tab-buttons {
    background: #f3f4f6;
    border-radius: 1rem;
    padding: 0.5rem;
    display: inline-flex;
    gap: 0.25rem;
    flex-wrap: wrap;
}

@media (max-width: 640px) {
    .asc-tab-buttons {
        width: 100%;
        justify-content: center;
    }
}

.asc-tab-btn {
    padding: 0.75rem 1.5rem;
    border-radius: 0.75rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    background: transparent;
    border: none;
    color: #6b7280;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    -webkit-tap-highlight-color: transparent;
    min-height: 48px;
    white-space: nowrap;
}

@media (min-width: 768px) {
    .asc-tab-btn {
        padding: 0.75rem 2rem;
        font-size: 1rem;
    }
}

.asc-tab-btn:hover {
    color: white;
    background: #8b5cf6;
}

.asc-tab-btn.active {
    background: white;
    color: #8b5cf6;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.asc-tab-btn i {
    font-size: 1rem;
}

/* Tab Content */
.asc-tab-content {
    display: none;
}

.asc-tab-content.active {
    display: block;
}

/* Main Content Layout */
.asc-main-content {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

@media (min-width: 1280px) {
    .asc-main-content {
        display: grid;
        grid-template-columns: 1fr 2fr;
        gap: 2rem;
        margin-bottom: 4rem;
    }
}

/* Text Input */
.asc-text-input {
    width: 100%;
    padding: 1rem 1.5rem;
    background: white;
    border: 2px solid #d1d5db;
    border-radius: 1rem;
    font-size: 1rem;
    font-weight: 500;
    color: #1f2937;
    transition: all 0.3s ease;
    -webkit-appearance: none;
}

@media (min-width: 768px) {
    .asc-text-input {
        padding: 1rem 1.5rem;
        font-size: 1.125rem;
    }
}

.asc-text-input:focus {
    outline: none;
    border-color: #8b5cf6;
    box-shadow: 0 0 0 4px rgba(139, 92, 246, 0.1);
}

.asc-text-input::placeholder {
    color: #9ca3af;
}

/* Environment Buttons */
.asc-environment-buttons {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

@media (min-width: 640px) {
    .asc-environment-buttons {
        grid-template-columns: repeat(2, 1fr);
    }
}

.asc-env-btn {
    padding: 1rem;
    border: 3px solid #d1d5db;
    background: white;
    border-radius: 0.75rem;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
    -webkit-tap-highlight-color: transparent;
    min-height: 100px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

@media (max-width: 640px) {
    .asc-env-btn {
        padding: 1.25rem;
        min-height: 120px;
    }
}

.asc-env-btn:hover {
    border-color: #8b5cf6;
    background: #f8fafc;
}

.asc-env-btn.active {
    border-color: #8b5cf6;
    background: #f3e8ff;
    box-shadow: 0 4px 6px -1px rgba(139, 92, 246, 0.3);
    transform: scale(1.02);
}

.asc-env-icon {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.asc-env-name {
    font-weight: 700;
    font-size: 0.875rem;
    margin-bottom: 0.25rem;
    color: #111827 !important;
    display: block;
}

@media (min-width: 768px) {
    .asc-env-name {
        font-size: 1rem;
    }
}

.asc-env-btn.active .asc-env-name {
    color: #7c3aed !important;
}

.asc-env-speed {
    font-size: 0.75rem;
    color: #4b5563 !important;
    display: block;
}

@media (min-width: 768px) {
    .asc-env-speed {
        font-size: 0.875rem;
    }
}

.asc-env-btn.active .asc-env-speed {
    color: #7c3aed !important;
}

.asc-env-description {
    padding: 0.75rem;
    background: #dbeafe;
    border: 1px solid #93c5fd;
    border-radius: 0.75rem;
    font-size: 0.875rem;
    color: #1e40af;
}

/* Card Styles */
.asc-card {
    background: #f9fafb;
    border-radius: 1.5rem;
    padding: 1.5rem;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    border: 1px solid #e5e7eb;
    transition: all 0.3s ease;
}

@media (min-width: 768px) {
    .asc-card {
        padding: 2rem;
    }
}

.asc-card:hover {
    background: #f3f4f6;
    transform: translateY(-2px);
}

.asc-card-header {
    display: flex;
    align-items: center;
    margin-bottom: 1.5rem;
    justify-content: space-between;
}

@media (min-width: 768px) {
    .asc-card-header {
        margin-bottom: 2rem;
    }
}

.asc-card-header > div:first-child {
    display: flex;
    align-items: center;
}

.asc-card-icon {
    width: 2.5rem;
    height: 2.5rem;
    background: linear-gradient(135deg, #8b5cf6, #3b82f6);
    color: white;
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 1rem;
    font-size: 1.25rem;
}

@media (min-width: 768px) {
    .asc-card-icon {
        width: 3rem;
        height: 3rem;
        font-size: 1.5rem;
    }
}

.asc-results-icon {
    background: linear-gradient(135deg, #10b981, #059669);
}

.asc-goals-icon {
    background: linear-gradient(135deg, #8b5cf6, #ec4899);
}

.asc-sessions-icon {
    background: linear-gradient(135deg, #10b981, #059669);
}

.asc-card-header h2 {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1f2937;
    margin: 0;
}

@media (min-width: 768px) {
    .asc-card-header h2 {
        font-size: 1.5rem;
    }
}

/* Save Session Button */
.asc-save-btn {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 1rem 1.5rem;
    background: linear-gradient(135deg, #ecfdf5, #d1fae5);
    border: 2px solid #6ee7b7;
    color: #059669;
    border-radius: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-bottom: 1rem;
    -webkit-tap-highlight-color: transparent;
    min-height: 48px;
}

.asc-save-btn:hover {
    background: linear-gradient(135deg, #d1fae5, #a7f3d0);
    border-color: #34d399;
    transform: scale(1.02);
}

.asc-save-btn.asc-saved {
    background: linear-gradient(135deg, #a7f3d0, #6ee7b7);
    border-color: #10b981;
}

/* Input Styles */
.asc-input-group {
    margin-bottom: 2rem;
}

@media (min-width: 768px) {
    .asc-input-group {
        margin-bottom: 2.5rem;
    }
}

.asc-label {
    display: block;
    font-size: 0.875rem;
    font-weight: 700;
    color: #8b5cf6;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 1rem;
}

.asc-time-inputs {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.75rem;
}

@media (min-width: 768px) {
    .asc-time-inputs {
        gap: 1rem;
    }
}

.asc-time-input {
    text-align: center;
}

.asc-time-input label {
    display: block;
    font-size: 0.75rem;
    color: #6b7280;
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.asc-time-input input {
    width: 100%;
    padding: 0.75rem;
    background: white;
    border: 2px solid #d1d5db;
    border-radius: 1rem;
    text-align: center;
    font-size: 1rem;
    font-weight: 700;
    color: #1f2937;
    transition: all 0.3s ease;
    -webkit-appearance: none;
    -moz-appearance: textfield;
    min-height: 48px;
}

@media (min-width: 768px) {
    .asc-time-input input {
        padding: 1rem;
        font-size: 1.25rem;
    }
}

.asc-time-input input:focus {
    outline: none;
    border-color: #8b5cf6;
    box-shadow: 0 0 0 4px rgba(139, 92, 246, 0.1);
}

.asc-time-input input:hover {
    background: #f9fafb;
}

/* Hide number input spinners */
.asc-time-input input::-webkit-outer-spin-button,
.asc-time-input input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Speed Buttons */
.asc-speed-buttons {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

@media (min-width: 768px) {
    .asc-speed-buttons {
        gap: 0.75rem;
    }
}

.asc-speed-btn {
    padding: 0.75rem 0.5rem;
    border: 2px solid #d1d5db;
    background: white;
    color: #1f2937;
    border-radius: 0.75rem;
    font-weight: 800;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    font-size: 0.875rem;
    -webkit-tap-highlight-color: transparent;
    min-height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
}

@media (min-width: 768px) {
    .asc-speed-btn {
        padding: 0.75rem 1rem;
        font-size: 1rem;
    }
}

.asc-speed-btn:hover {
    background: #8b5cf6 !important;
    color: #ffffff !important;
    border-color: #8b5cf6 !important;
    transform: scale(1.05);
    text-shadow: none !important;
}

.asc-speed-btn.active {
    background: linear-gradient(135deg, #8b5cf6, #3b82f6);
    color: white;
    border-color: transparent;
    box-shadow: 0 10px 15px -3px rgba(139, 92, 246, 0.3);
    transform: scale(1.05);
}

.asc-touch-active {
    transform: scale(0.95) !important;
    transition: transform 0.1s ease !important;
}

/* Custom Speed Input */
.asc-custom-speed {
    position: relative;
}

.asc-custom-speed label {
    display: block;
    font-size: 0.75rem;
    color: #6b7280;
    font-weight: 500;
    margin-bottom: 0.75rem;
}

.asc-custom-speed input {
    width: 100%;
    padding: 0.75rem 2rem 0.75rem 1rem;
    background: white;
    border: 2px solid #d1d5db;
    border-radius: 1rem;
    font-size: 1rem;
    font-weight: 700;
    color: #1f2937;
    transition: all 0.3s ease;
    -webkit-appearance: none;
    -moz-appearance: textfield;
    min-height: 48px;
}

@media (min-width: 768px) {
    .asc-custom-speed input {
        padding: 1rem 2rem 1rem 1.5rem;
        font-size: 1.125rem;
    }
}

.asc-custom-speed input:focus {
    outline: none;
    border-color: #8b5cf6;
    box-shadow: 0 0 0 4px rgba(139, 92, 246, 0.1);
}

.asc-custom-speed input::-webkit-outer-spin-button,
.asc-custom-speed input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.asc-speed-suffix {
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: #6b7280;
    font-weight: 600;
    margin-top: 0.625rem;
}

@media (min-width: 768px) {
    .asc-speed-suffix {
        margin-top: 1.25rem;
    }
}

/* Reset Button */
.asc-reset-btn {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 1rem 1.5rem;
    background: linear-gradient(135deg, #fef2f2, #fce7e7);
    border: 2px solid #fca5a5;
    color: #dc2626;
    border-radius: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    -webkit-tap-highlight-color: transparent;
    min-height: 48px;
}

.asc-reset-btn:hover {
    background: linear-gradient(135deg, #fee2e2, #fecaca);
    border-color: #f87171;
    transform: scale(1.02);
}

.asc-reset-active {
    transform: scale(0.98) !important;
    background: linear-gradient(135deg, #fee2e2, #fecaca) !important;
}

/* Reading Goals Integration */
.asc-goals-integration {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

@media (min-width: 768px) {
    .asc-goals-integration {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }
}

.asc-goal-card {
    padding: 1.25rem;
    border-radius: 1rem;
    border: 2px solid;
    transition: all 0.3s ease;
}

@media (min-width: 768px) {
    .asc-goal-card {
        padding: 1.5rem;
    }
}

.asc-goal-card:first-child {
    background: linear-gradient(135deg, #faf5ff, #f3e8ff);
    border-color: #c4b5fd;
}

.asc-goal-card:last-child {
    background: linear-gradient(135deg, #fef3c7, #fde68a);
    border-color: #fbbf24;
}

.asc-goal-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
}

.asc-goal-header i {
    color: #8b5cf6;
    font-size: 1rem;
}

.asc-goal-card:last-child .asc-goal-header i {
    color: #f59e0b;
}

.asc-goal-header span {
    font-size: 0.75rem;
    font-weight: 700;
    color: #8b5cf6;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.asc-goal-card:last-child .asc-goal-header span {
    color: #f59e0b;
}

.asc-goal-value {
    font-size: 1.125rem;
    font-weight: 900;
    color: #1f2937;
    margin-bottom: 0.5rem;
}

@media (min-width: 768px) {
    .asc-goal-value {
        font-size: 1.25rem;
    }
}

.asc-goal-subtitle {
    font-size: 0.75rem;
    color: #6b7280;
}

/* Results Styles */
.asc-empty-state {
    text-align: center;
    padding: 2rem 1rem;
}

@media (min-width: 768px) {
    .asc-empty-state {
        padding: 4rem 2rem;
    }
}

.asc-empty-icon {
    width: 4rem;
    height: 4rem;
    background: linear-gradient(135deg, #e0e7ff, #c7d2fe);
    border: 2px solid #a5b4fc;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    font-size: 2rem;
    color: #8b5cf6;
}

@media (min-width: 768px) {
    .asc-empty-icon {
        width: 6rem;
        height: 6rem;
        font-size: 3rem;
    }
}

/* Goals Tab Styles */
.asc-goals-content {
    max-width: 4xl;
    margin: 0 auto;
}

.asc-goals-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    margin-bottom: 2rem;
}

@media (min-width: 768px) {
    .asc-goals-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.asc-goal-settings {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.asc-goal-input {
    width: 100%;
    padding: 1rem 1.5rem;
    background: white;
    border: 2px solid #d1d5db;
    border-radius: 1rem;
    font-size: 1rem;
    font-weight: 700;
    color: #1f2937;
    transition: all 0.3s ease;
    -webkit-appearance: none;
    -moz-appearance: textfield;
    min-height: 48px;
}

@media (min-width: 768px) {
    .asc-goal-input {
        font-size: 1.125rem;
    }
}

.asc-goal-input:focus {
    outline: none;
    border-color: #8b5cf6;
    box-shadow: 0 0 0 4px rgba(139, 92, 246, 0.1);
}

.asc-goal-input::-webkit-outer-spin-button,
.asc-goal-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.asc-goal-stats {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.asc-goal-stat-card {
    padding: 1.25rem;
    border-radius: 1rem;
    border: 2px solid;
    transition: all 0.3s ease;
}

@media (min-width: 768px) {
    .asc-goal-stat-card {
        padding: 1.5rem;
    }
}

.asc-goal-stat-card:hover {
    transform: translateY(-2px);
}

.asc-monthly {
    background: linear-gradient(135deg, #dbeafe, #bfdbfe);
    border-color: #93c5fd;
}

.asc-yearly {
    background: linear-gradient(135deg, #d1fae5, #a7f3d0);
    border-color: #6ee7b7;
}

.asc-daily {
    background: linear-gradient(135deg, #faf5ff, #f3e8ff);
    border-color: #c4b5fd;
}

.asc-goal-stat-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
}

.asc-goal-stat-header i {
    font-size: 1rem;
}

.asc-monthly .asc-goal-stat-header i {
    color: #3b82f6;
}

.asc-yearly .asc-goal-stat-header i {
    color: #059669;
}

.asc-daily .asc-goal-stat-header i {
    color: #8b5cf6;
}

.asc-goal-stat-header span {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.asc-monthly .asc-goal-stat-header span {
    color: #3b82f6;
}

.asc-yearly .asc-goal-stat-header span {
    color: #059669;
}

.asc-daily .asc-goal-stat-header span {
    color: #8b5cf6;
}

.asc-goal-stat-value {
    font-size: 1.5rem;
    font-weight: 900;
    color: #1f2937;
    margin-bottom: 0.5rem;
}

@media (min-width: 768px) {
    .asc-goal-stat-value {
        font-size: 2rem;
    }
}

.asc-goal-stat-subtitle {
    font-size: 0.75rem;
    color: #6b7280;
}

@media (min-width: 768px) {
    .asc-goal-stat-subtitle {
        font-size: 0.875rem;
    }
}

/* Tips Grid */
.asc-tips-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    margin-top: 2rem;
}

@media (min-width: 768px) {
    .asc-tips-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.asc-tip-card {
    background: white;
    border-radius: 1rem;
    padding: 1.5rem;
    border: 2px solid #e5e7eb;
}

.asc-tip-card h3 {
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.asc-tip-card h3 i {
    color: #f59e0b;
}

.asc-tip-card ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.asc-tip-card li {
    font-size: 0.875rem;
    color: #6b7280;
    margin-bottom: 0.5rem;
    line-height: 1.5;
}

/* Sessions Tab Styles */
.asc-sessions-content {
    max-width: 4xl;
    margin: 0 auto;
}

.asc-clear-btn {
    padding: 0.5rem 1rem;
    background: #fee2e2;
    color: #dc2626;
    border: 1px solid #fca5a5;
    border-radius: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.875rem;
    min-height: 40px;
}

.asc-clear-btn:hover {
    background: #fecaca;
    border-color: #f87171;
}

.asc-session-stats {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
    margin-bottom: 2rem;
}

@media (min-width: 640px) {
    .asc-session-stats {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 768px) {
    .asc-session-stats {
        gap: 1.5rem;
    }
}

.asc-session-stat {
    padding: 1.25rem;
    border-radius: 1rem;
    text-align: center;
    border: 2px solid;
    transition: all 0.3s ease;
}

@media (min-width: 768px) {
    .asc-session-stat {
        padding: 1.5rem;
    }
}

.asc-session-stat:hover {
    transform: translateY(-2px);
}

.asc-session-stat:nth-child(1) {
    background: linear-gradient(135deg, #dbeafe, #bfdbfe);
    border-color: #93c5fd;
}

.asc-session-stat:nth-child(2) {
    background: linear-gradient(135deg, #d1fae5, #a7f3d0);
    border-color: #6ee7b7;
}

.asc-session-stat:nth-child(3) {
    background: linear-gradient(135deg, #faf5ff, #f3e8ff);
    border-color: #c4b5fd;
}

.asc-session-stat-value {
    font-size: 1.5rem;
    font-weight: 900;
    color: #1f2937;
    margin-bottom: 0.25rem;
}

@media (min-width: 768px) {
    .asc-session-stat-value {
        font-size: 2rem;
    }
}

.asc-session-stat-label {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #6b7280;
}

.asc-session-item {
    background: white;
    border-radius: 1rem;
    padding: 1.5rem;
    border: 2px solid #e5e7eb;
    margin-bottom: 1rem;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

@media (min-width: 768px) {
    .asc-session-item {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        gap: 0;
    }
}

.asc-session-item:hover {
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.asc-session-main {
    flex: 1;
}

.asc-session-title {
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 0.5rem;
    font-size: 1rem;
}

@media (min-width: 768px) {
    .asc-session-title {
        font-size: 1.125rem;
    }
}

.asc-session-details {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    font-size: 0.75rem;
    color: #6b7280;
}

@media (min-width: 768px) {
    .asc-session-details {
        font-size: 0.875rem;
    }
}

.asc-session-details span {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.asc-session-time {
    text-align: center;
}

@media (min-width: 768px) {
    .asc-session-time {
        text-align: right;
    }
}

.asc-session-duration {
    font-size: 1.125rem;
    font-weight: 700;
    color: #1f2937;
    font-family: 'Courier New', monospace;
}

@media (min-width: 768px) {
    .asc-session-duration {
        font-size: 1.25rem;
    }
}

.asc-session-label {
    font-size: 0.75rem;
    color: #6b7280;
}

.asc-empty-sessions {
    text-align: center;
    padding: 2rem 1rem;
}

@media (min-width: 768px) {
    .asc-empty-sessions {
        padding: 4rem 2rem;
    }
}

.asc-empty-sessions .asc-empty-icon {
    background: linear-gradient(135deg, #d1fae5, #a7f3d0);
    border-color: #6ee7b7;
    color: #059669;
}

.asc-empty-state h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 0.75rem;
}

@media (min-width: 768px) {
    .asc-empty-state h3 {
        font-size: 1.5rem;
    }
}

.asc-empty-sessions h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 0.75rem;
}

@media (min-width: 768px) {
    .asc-empty-sessions h3 {
        font-size: 1.5rem;
    }
}

.asc-empty-state p {
    color: #6b7280;
    font-size: 1rem;
    max-width: 24rem;
    margin: 0 auto;
    line-height: 1.6;
}

@media (min-width: 768px) {
    .asc-empty-state p {
        font-size: 1.125rem;
    }
}

.asc-empty-sessions p {
    color: #6b7280;
    font-size: 1rem;
    max-width: 24rem;
    margin: 0 auto;
    line-height: 1.6;
}

@media (min-width: 768px) {
    .asc-empty-sessions p {
        font-size: 1.125rem;
    }
}

/* Results Grid */
.asc-results-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

@media (min-width: 768px) {
    .asc-results-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }
}

.asc-result-card {
    padding: 1.25rem;
    border-radius: 1rem;
    border: 2px solid;
    transition: all 0.3s ease;
}

@media (min-width: 768px) {
    .asc-result-card {
        padding: 1.5rem;
    }
}

.asc-result-card:hover {
    transform: translateY(-2px);
}

.asc-original {
    background: linear-gradient(135deg, #f3f4f6, #e5e7eb);
    border-color: #d1d5db;
}

.asc-new {
    background: linear-gradient(135deg, #dbeafe, #bfdbfe);
    border-color: #93c5fd;
}

.asc-result-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
}

.asc-result-header i {
    color: #6b7280;
    font-size: 1rem;
}

@media (min-width: 768px) {
    .asc-result-header i {
        font-size: 1.25rem;
    }
}

.asc-new .asc-result-header i {
    color: #3b82f6;
}

.asc-result-header span {
    font-size: 0.75rem;
    font-weight: 700;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

@media (min-width: 768px) {
    .asc-result-header span {
        font-size: 0.875rem;
    }
}

.asc-new .asc-result-header span {
    color: #3b82f6;
}

.asc-result-time {
    font-size: 1.75rem;
    font-weight: 900;
    color: #1f2937;
    margin-bottom: 0.5rem;
    font-family: 'Courier New', monospace;
}

@media (min-width: 768px) {
    .asc-result-time {
        font-size: 2.5rem;
    }
}

.asc-result-subtitle {
    font-size: 0.75rem;
    color: #6b7280;
}

@media (min-width: 768px) {
    .asc-result-subtitle {
        font-size: 0.875rem;
    }
}

.asc-new .asc-result-subtitle {
    color: #3b82f6;
}

/* Time Saved */
.asc-time-saved {
    background: linear-gradient(135deg, #d1fae5, #a7f3d0);
    border: 2px solid #6ee7b7;
    border-radius: 1rem;
    padding: 1.5rem;
    text-align: center;
    margin-bottom: 1.5rem;
    transition: all 0.3s ease;
}

@media (min-width: 768px) {
    .asc-time-saved {
        padding: 2rem;
    }
}

.asc-time-saved:hover {
    transform: translateY(-2px);
}

.asc-saved-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

@media (min-width: 768px) {
    .asc-saved-header {
        gap: 0.75rem;
    }
}

.asc-saved-header i {
    font-size: 1.5rem;
    color: #059669;
}

@media (min-width: 768px) {
    .asc-saved-header i {
        font-size: 2rem;
    }
}

.asc-saved-header span {
    font-size: 1rem;
    font-weight: 700;
    color: #059669;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

@media (min-width: 768px) {
    .asc-saved-header span {
        font-size: 1.125rem;
    }
}

.asc-saved-time {
    font-size: 2.5rem;
    font-weight: 900;
    color: #1f2937;
    margin-bottom: 1rem;
    font-family: 'Courier New', monospace;
}

@media (min-width: 768px) {
    .asc-saved-time {
        font-size: 3.75rem;
    }
}

.asc-saved-percentage {
    font-size: 1rem;
    font-weight: 700;
    color: #059669;
}

@media (min-width: 768px) {
    .asc-saved-percentage {
        font-size: 1.25rem;
    }
}

/* Statistics Grid */
.asc-stats-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

@media (min-width: 640px) {
    .asc-stats-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 768px) {
    .asc-stats-grid {
        gap: 1rem;
    }
}

.asc-stat-card {
    padding: 1rem;
    border-radius: 0.75rem;
    text-align: center;
    border: 2px solid;
    transition: all 0.3s ease;
}

@media (min-width: 768px) {
    .asc-stat-card {
        padding: 1.5rem;
    }
}

.asc-stat-card:hover {
    transform: translateY(-2px);
}

.asc-stat-boost {
    background: linear-gradient(135deg, #faf5ff, #f3e8ff);
    border-color: #c4b5fd;
}

.asc-stat-efficiency {
    background: linear-gradient(135deg, #fef3c7, #fde68a);
    border-color: #fbbf24;
}

.asc-stat-faster {
    background: linear-gradient(135deg, #ecfdf5, #d1fae5);
    border-color: #6ee7b7;
}

.asc-stat-value {
    font-size: 1.25rem;
    font-weight: 900;
    color: #1f2937;
    margin-bottom: 0.25rem;
}

@media (min-width: 768px) {
    .asc-stat-value {
        font-size: 1.5rem;
    }
}

.asc-stat-label {
    font-size: 0.625rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #6b7280;
}

@media (min-width: 768px) {
    .asc-stat-label {
        font-size: 0.75rem;
    }
}

/* Progress Bar */
.asc-progress-container {
    background: white;
    border-radius: 1rem;
    padding: 1.25rem;
    border: 2px solid #e5e7eb;
}

@media (min-width: 768px) {
    .asc-progress-container {
        padding: 1.5rem;
    }
}

.asc-progress-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.asc-progress-header span:first-child {
    font-size: 0.75rem;
    font-weight: 700;
    color: #6b7280;
}

@media (min-width: 768px) {
    .asc-progress-header span:first-child {
        font-size: 0.875rem;
    }
}

.asc-progress-header span:last-child {
    font-size: 0.75rem;
    font-weight: 700;
    color: #1f2937;
}

@media (min-width: 768px) {
    .asc-progress-header span:last-child {
        font-size: 0.875rem;
    }
}

.asc-progress-bar {
    width: 100%;
    height: 0.75rem;
    background: #e5e7eb;
    border-radius: 0.375rem;
    overflow: hidden;
}

@media (min-width: 768px) {
    .asc-progress-bar {
        height: 1rem;
        border-radius: 0.5rem;
    }
}

.asc-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #10b981, #059669);
    border-radius: 0.375rem;
    transition: width 1s ease-out;
    width: 0%;
    box-shadow: 0 0 10px rgba(16, 185, 129, 0.5);
}

@media (min-width: 768px) {
    .asc-progress-fill {
        border-radius: 0.5rem;
    }
}

/* Feature Cards */
.asc-features-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    margin-top: 2rem;
}

@media (min-width: 768px) {
    .asc-features-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 2rem;
        margin-top: 4rem;
    }
}

.asc-feature-card {
    background: #f9fafb;
    border-radius: 1rem;
    padding: 1.5rem;
    text-align: center;
    border: 2px solid #e5e7eb;
    transition: all 0.3s ease;
}

@media (min-width: 768px) {
    .asc-feature-card {
        padding: 2rem;
    }
}

.asc-feature-card:hover {
    background: #f3f4f6;
    transform: translateY(-4px);
}

.asc-feature-icon {
    width: 3rem;
    height: 3rem;
    border-radius: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    font-size: 1.5rem;
    color: white;
}

@media (min-width: 768px) {
    .asc-feature-icon {
        width: 4rem;
        height: 4rem;
        font-size: 2rem;
    }
}

.asc-feature-purple {
    background: linear-gradient(135deg, #8b5cf6, #ec4899);
}

.asc-feature-goals {
    background: linear-gradient(135deg, #8b5cf6, #ec4899);
}

.asc-feature-sessions {
    background: linear-gradient(135deg, #3b82f6, #06b6d4);
}

.asc-feature-smart {
    background: linear-gradient(135deg, #10b981, #059669);
}

.asc-feature-card h3 {
    font-size: 1.125rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 0.75rem;
}

@media (min-width: 768px) {
    .asc-feature-card h3 {
        font-size: 1.25rem;
    }
}

.asc-feature-card p {
    color: #6b7280;
    line-height: 1.6;
    font-size: 0.875rem;
}

@media (min-width: 768px) {
    .asc-feature-card p {
        font-size: 1rem;
    }
}

/* Mobile Optimizations */
.asc-mobile-optimized {
    -webkit-overflow-scrolling: touch;
}

.asc-mobile-optimized input {
    font-size: 16px !important; /* Prevent zoom on iOS */
}

/* Touch improvements */
@media (hover: none) and (pointer: coarse) {
    /* Disable hover effects on touch devices */
    .asc-speed-btn:hover,
    .asc-env-btn:hover,
    .asc-tab-btn:hover,
    .asc-reset-btn:hover,
    .asc-save-btn:hover {
        transform: none !important;
        background: initial !important;
        border-color: initial !important;
    }
    
    /* Better touch feedback */
    .asc-touch-active {
        transform: scale(0.95) !important;
        opacity: 0.8 !important;
        transition: all 0.1s ease !important;
    }
    
    /* Prevent text selection on buttons */
    .asc-speed-btn,
    .asc-env-btn,
    .asc-tab-btn,
    .asc-reset-btn,
    .asc-save-btn {
        -webkit-user-select: none !important;
        -moz-user-select: none !important;
        -ms-user-select: none !important;
        user-select: none !important;
        -webkit-touch-callout: none !important;
        touch-action: manipulation;
    }
    
    /* Ensure body can scroll properly */
    body {
        touch-action: pan-y !important;
        overflow: auto !important;
    }
    
    /* Allow scrolling on container */
    .asc-container {
        touch-action: pan-y !important;
    }
}

/* Accessibility improvements */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    .asc-container::before,
    .asc-container::after {
        animation: none;
    }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .bg-gray-50 {
        border-width: 3px;
    }
    
    button {
        border-width: 3px;
    }
    
    input {
        border-width: 3px;
    }
}

/* Responsive Design Improvements */
@media (max-width: 640px) {
    .grid {
        grid-template-columns: 1fr !important;
    }
    
    .xl\:grid-cols-3 {
        grid-template-columns: 1fr !important;
    }
    
    .md\:grid-cols-2 {
        grid-template-columns: 1fr !important;
    }
    
    .md\:grid-cols-3 {
        grid-template-columns: 1fr !important;
    }
    
    .text-5xl,
    .md\:text-6xl {
        font-size: 2.5rem !important;
    }
    
    .text-lg,
    .md\:text-xl {
        font-size: 1rem !important;
    }
    
    .p-8 {
        padding: 1rem !important;
    }
    
    .py-12 {
        padding-top: 2rem !important;
        padding-bottom: 2rem !important;
    }
    
    .mb-16 {
        margin-bottom: 2rem !important;
    }
    
    .gap-8 {
        gap: 1rem !important;
    }
    
    .space-x-8 > * + * {
        margin-left: 1rem !important;
    }
    
    .asc-container {
        padding: 0.5rem;
    }
    
    .asc-title {
        font-size: 1.75rem;
        padding: 0 0.5rem;
    }
    
    .asc-description {
        font-size: 0.875rem;
        padding: 0 0.5rem;
    }
    
    .asc-features {
        flex-direction: column;
        align-items: center;
        gap: 0.75rem;
    }
    
    .asc-tab-buttons {
        flex-direction: column;
        width: 100%;
        gap: 0.5rem;
    }
    
    .asc-tab-btn {
        width: 100%;
        justify-content: center;
        padding: 1rem;
    }
    
    .asc-environment-buttons {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .asc-env-btn {
        min-height: 100px;
        padding: 1rem;
    }
    
    .asc-speed-buttons {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.75rem;
    }
    
    .asc-speed-btn {
        min-height: 52px;
        font-size: 1rem;
        font-weight: 900;
    }
    
    .asc-stats-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .asc-session-stats {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .asc-session-item {
        padding: 1rem;
    }
    
    .asc-session-details {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .asc-card {
        padding: 1rem;
        border-radius: 1rem;
    }
    
    .asc-card-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    
    .asc-card-header > div:first-child {
        width: 100%;
    }
    
    .asc-clear-btn {
        width: 100%;
        padding: 0.75rem;
    }
}

@media (max-width: 768px) {
    /* Force single column layout on mobile */
    .grid {
        display: flex !important;
        flex-direction: column !important;
        gap: 1rem !important;
    }
    
    /* Ensure proper spacing on mobile */
    .rounded-3xl {
        border-radius: 1rem !important;
    }
    
    /* Mobile-friendly button sizes */
    button {
        min-height: 48px !important;
        padding: 0.75rem 1rem !important;
    }
    
    /* Mobile input improvements */
    input[type="number"] {
        font-size: 16px !important;
        padding: 0.75rem !important;
    }
    
    /* Mobile text sizing */
    .text-2xl {
        font-size: 1.5rem !important;
    }
    
    .text-3xl,
    .md\:text-4xl {
        font-size: 1.75rem !important;
    }
    
    .text-4xl,
    .md\:text-6xl {
        font-size: 2rem !important;
    }
    
    /* Prevent accidental touches during scrolling */
    .asc-speed-btn,
    .asc-env-btn {
        touch-action: manipulation;
        -webkit-touch-callout: none;
        -webkit-user-select: none;
        -moz-user-select: none;
        -ms-user-select: none;
        user-select: none;
    }
    
    /* Reduce touch sensitivity */
    .asc-speed-btn:active,
    .asc-env-btn:active {
        transform: none !important;
        background: rgba(139, 92, 246, 0.1) !important;
        transition: background 0.1s ease !important;
    }
    
    /* Better button spacing for touch */
    .asc-speed-buttons {
        gap: 1rem !important;
    }
    
    .asc-environment-buttons {
        gap: 1rem !important;
    }
    
    /* Prevent keyboard on non-input elements */
    .asc-speed-btn,
    .asc-env-btn,
    .asc-tab-btn {
        -webkit-user-select: none;
        -moz-user-select: none;
        -ms-user-select: none;
        user-select: none;
        -webkit-touch-callout: none;
    }
}

/* Flexible container sizing */
.max-w-7xl {
    max-width: 100% !important;
    padding-left: 1rem !important;
    padding-right: 1rem !important;
}

@media (min-width: 640px) {
    .max-w-7xl {
        max-width: 640px !important;
        padding-left: 2rem !important;
        padding-right: 2rem !important;
    }
}

@media (min-width: 768px) {
    .max-w-7xl {
        max-width: 768px !important;
    }
}

@media (min-width: 1024px) {
    .max-w-7xl {
        max-width: 1024px !important;
    }
}

@media (min-width: 1280px) {
    .max-w-7xl {
        max-width: 1280px !important;
    }
}

/* Input Type Specific Styles */
input[type="text"] {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

input[type="number"] {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    -moz-appearance: textfield;
}

/* Better touch targets */
@media (pointer: coarse) {
    button {
        min-height: 44px !important;
        min-width: 44px !important;
    }
    
    .asc-speed-btn {
        padding: 1rem 0.75rem !important;
        margin: 0.25rem !important;
    }
    
    .asc-env-btn {
        padding: 1.25rem !important;
        margin: 0.25rem 0 !important;
    }
}

/* Ensure proper input sizing on mobile */
input[type="number"],
input[type="text"] {
    font-size: 16px !important; /* Prevent zoom on iOS */
    -webkit-appearance: none;
    -moz-appearance: textfield;
}

/* Better button accessibility */
button {
    min-height: 44px;
    -webkit-tap-highlight-color: transparent;
}

/* Improved focus states */
button:focus,
input:focus {
    outline: 2px solid #8b5cf6;
    outline-offset: 2px;
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Better text selection */
::selection {
    background-color: rgba(139, 92, 246, 0.2);
    color: inherit;
}