:root {
    --primary: #2c3e50;
    --secondary: #ff6b6b;
    --accent: #3d5a80;
    --light-bg: #f8f9fa;
    --teal: #4ecdc4;
    --border-color: #e0e0e0;
    --text-color: #000000;
    --text-light: #666;
    --shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    --radius: 8px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Times New Roman', Times, serif;
    font-size: 1rem;
    line-height: 1.6;
    color: #000;
    background-color: var(--light-bg);
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 10px;
}

/* Main Layout */
.main-content {
    
}

.calculator-grid {
    display: grid;
    gap: 0 20px;
}

/* Calculator Styles */
#converter-tool {
    background-color: white;
    border-radius: var(--radius);
    padding: 20px;
    box-shadow: var(--shadow);
}

h1 {
    font-size: 1.5rem;
    margin-bottom: 20px;
    color: #000;
    border-bottom: 2px solid var(--teal);
    padding-bottom: 10px;
    text-align: center;
}

h2 {
    font-size: 1.375rem;
    margin: 20px 0 15px;
    color: #ff6b6b;
}

h3 {
    font-size: 1.25rem;
    margin: 15px 0 10px;
    color: #000;
}

h4 {
    font-size: 1.125rem;
    color: #000;
}

.settings-row {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 20px;
}

.setting-group {
    flex: 1;
    min-width: 200px;
}

label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
    color: #000;
}

select, input {
    width: 100%;
    padding: 10px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius);
    font-family: inherit;
    font-size: 1rem;
    color: #000;
}

/* Toggle Switch */
.toggle-group {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.toggle-label {
    margin-right: 10px;
    font-weight: bold;
    color: #000;
}

.toggle-switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 24px;
}

.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: #ccc;
    transition: .4s;
    border-radius: 24px;
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 16px;
    width: 16px;
    left: 4px;
    bottom: 4px;
    background-color: white;
    transition: .4s;
    border-radius: 50%;
}

input:checked + .toggle-slider {
    background-color: var(--teal);
}

input:checked + .toggle-slider:before {
    transform: translateX(26px);
}

/* Daily Entries */
.daily-entry {
    background-color: var(--light-bg);
    padding: 15px;
    border-radius: var(--radius);
    margin-bottom: 15px;
    position: relative;
}

.day-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.day-name {
    font-weight: bold;
    color: #000;
}

.time-inputs {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.break-input {
    grid-column: 1 / -1;
}

.day-actions {
    display: flex;
    justify-content: space-between;
    margin-top: 10px;
}

.add-shift {
    background: none;
    border: none;
    color: #000;
    cursor: pointer;
    font-size: 0.875rem;
    display: flex;
    align-items: center;
    gap: 5px;
}

.reset-day {
    background-color: var(--text-light);
    color: white;
    border: none;
    border-radius: var(--radius);
    padding: 5px 10px;
    font-size: 0.875rem;
    cursor: pointer;
}

/* Buttons */
.action-buttons {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin: 25px 0;
}

button {
    padding: 12px 20px;
    border: none;
    border-radius: var(--radius);
    font-family: inherit;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s;
    width: 100%;
    color: #000;
}

.btn-calculate {
    background-color: #4ecdc4;
    color: white;
}

.btn-reset {
    background-color: #ff6b6b;
    color: white;
}

.btn-calculate:hover {
    background-color: #3db8af;
}

.btn-reset:hover {
    background-color: #e55a5a;
}

/* Spinner */
.spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255,255,255,.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 1s ease-in-out infinite;
    margin-right: 10px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Results */
.results-container {
    background-color: var(--light-bg);
    padding: 20px;
    border-radius: var(--radius);
    margin-top: 20px;
    display: none;
}

.summary-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-bottom: 20px;
}

.summary-card {
    background-color: white;
    padding: 15px;
    border-radius: var(--radius);
    text-align: center;
    box-shadow: var(--shadow);
    color: #000;
}

.summary-value {
    font-size: 1.25rem;
    font-weight: bold;
    color: #000;
    margin: 10px 0;
}

.overtime {
    color: #ff6b6b;
}

/* Export Options */
.export-options {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 20px;
    justify-content: center;
}

.export-btn {
    background-color: var(--accent);
    color: white;
    padding: 10px 15px;
    display: flex;
    align-items: center;
    gap: 8px;
    width: auto;
}

/* Chart Container */
.chart-container {
    width: 100%;
    max-width: 250px;
    margin: 20px auto;
    height: 200px;
}

/* Plain Text Results for Export */
.plain-text-results {
    display: none;
    background-color: white;
    padding: 20px;
    border-radius: var(--radius);
    margin-top: 20px;
    font-family: 'Times New Roman', Times, serif;
    line-height: 1.6;
}

.plain-text-results h2 {
    color: #ff6b6b;
    border-bottom: 2px solid var(--teal);
    padding-bottom: 10px;
    margin-bottom: 15px;
    font-size: 1.375rem;
}

.plain-text-results .result-item {
    margin-bottom: 10px;
    display: flex;
    justify-content: space-between;
    color: #000;
}

.plain-text-results .result-label {
    font-weight: bold;
    color: #000;
}

.plain-text-results .result-value {
    color: #000;
    font-size: 1.25rem;
}

.plain-text-results .overtime {
    color: #ff6b6b;
}

/* Ad Styles */
.ad-container {
    background-color: var(--light-bg);
    border: 1px dashed var(--border-color);
    border-radius: var(--radius);
    display: flex;
    justify-content: center;
    align-items: center;
    color: #000;
    font-style: italic;
}

#ad-left, #ad-right {
    width: 300px;
}

#ad-left {
    height: 250px;
}

#ad-right {
    height: 600px;
}

#ad-tablet {
    height: 250px;
    width: 300px;
    margin: 0 auto;
    margin-top: 20px;
}

#ad-mobile {
    height: 100px;
    width: 100%;
    max-width: 320px;
    margin: 0 auto;
    margin-top: 20px;
}

/* Updated Related Tools CSS */
#related-tools {
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
    display: none;
}

.tools-list {
    list-style: none;
}

.tools-list li {
    padding: 10px 0;
    border-bottom: 1px solid var(--border-color);
    color: #000;
}

.tools-list li:last-child {
    border-bottom: none;
}

.tools-list a {
    color: #000;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1rem;
}

.tools-list a:hover {
    color: var(--teal);
}

#related-tools-mobile {
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
    margin-top: 20px;
    display: none;
}

#related-tools-mobile h3 {
    margin-top: 0;
    color: #000;
    font-size: 1.25rem;
}

/* Mobile Layout (≤767px) */
.calculator-grid {
    grid-template-columns: 1fr;
}

#ad-left, #ad-right, #ad-tablet {
    display: none;
}

#related-tools-mobile {
    display: block;
}

h1 {
    font-size: 1.25rem;
}

h2 {
    font-size: 1.125rem;
}

h3 {
    font-size: 1rem;
}

h4 {
    font-size: 0.9375rem;
}

/* Tablet Layout (768px–1024px) */
@media (min-width: 768px) {
    h1 {
        font-size: 1.25rem;
    }

    h2 {
        font-size: 1.25rem;
    }

    h3 {
        font-size: 1.125rem;
    }

    h4 {
        font-size: 1rem;
    }

    #ad-tablet {
        display: flex;
    }

    #ad-mobile {
        display: none;
    }

    .calculator-grid {
        grid-template-columns: 1fr;
    }

    .time-inputs {
        grid-template-columns: 1fr 1fr 1fr;
    }

    .break-input {
        grid-column: auto;
    }

    .action-buttons {
        flex-direction: row;
    }

    #related-tools-mobile {
        display: block;
    }
}

/* Desktop Layout (≥1025px) */
@media (min-width: 1025px) {
    h1 {
        font-size: 1.5rem;
    }

    h2 {
        font-size: 1.375rem;
    }

    h3 {
        font-size: 1.25rem;
    }

    h4 {
        font-size: 1.125rem;
    }

    .calculator-grid {
        grid-template-columns: 300px 1fr 300px;
    }

    #ad-left, #ad-right {
        display: flex;
    }

    #ad-tablet, #ad-mobile {
        display: none;
    }

    #related-tools {
        display: block;
    }

    #related-tools-mobile {
        display: none;
    }

    .sidebar {
        position: sticky;
        top: 20px;
        align-self: start;
    }

    .time-inputs {
        grid-template-columns: 1fr 1fr 1fr 1fr;
    }

    .action-buttons {
        flex-direction: row;
    }
}

/* Utility Classes */
.hidden {
    display: none;
}

.text-center {
    text-align: center;
}

.mt-10 {
    margin-top: 10px;
}

.mb-10 {
    margin-bottom: 10px;
}

/* Add breadcrumb styles */
.breadcrumb {
    padding: 0px 10px;
    color: #000;
    margin-bottom: 5px;
    font-size: 1rem;
}

.breadcrumb a {
    color: #000;
    text-decoration: none;
    transition: color 0.3s;
}

.breadcrumb a:hover {
    color: var(--secondary);
    text-decoration: underline;
}

/* Form styles */
#time-card-form {
    margin: 0;
    padding: 0;
}

.mobile-table {
    overflow-x: auto;
    margin: 20px 0;
    border: 1px solid #eee;
    border-radius: 8px;
}
.mobile-table table {
    width: 100%;
    min-width: 600px;
    border-collapse: collapse;
}
.mobile-table th, .mobile-table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #eee;
}
.mobile-table th {
    background-color: #4ecdc4;
    font-weight: bold;
}
.mobile-table tr:nth-child(even) {
    background-color: #fafafa;
}