/* Styles specific to the Pomodoro Timer Tool */

.timer-section {
    text-align: center;
    padding: 2rem 1rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    /* Default to work mode color */
    background-color: var(--preview-bg);
    max-width: 400px;
    margin: 2rem auto; /* Center the timer section */
    /* Add transition for background color */
    transition: background-color 0.5s ease-in-out, border-color 0.5s ease-in-out;
    position: relative; /* Needed for potential pseudo-elements if desired */
}

/* Work Mode Styling */
.timer-section.work-mode {
    background-color: rgba(40, 167, 69, 0.1); /* Light green tint for work */
     border-color: #28a745; /* Green border */
}
body.dark-mode .timer-section.work-mode {
     background-color: rgba(40, 167, 69, 0.15); /* Slightly stronger green for dark */
     border-color: #34c759; /* Brighter green border for dark */
}


/* Break Mode Styling */
.timer-section.break-mode {
    background-color: rgba(0, 123, 255, 0.1); /* Light blue tint for work */
    border-color: var(--accent-color-light);
}
body.dark-mode .timer-section.break-mode {
     background-color: rgba(102, 191, 255, 0.15); /* Slightly stronger blue for dark */
     border-color: var(--accent-color-dark);
}


#timer-display {
    font-size: 4rem;
    font-weight: bold;
    margin-bottom: 1.5rem;
    color: var(--text-color); /* Use standard text color, background indicates state */
}

.timer-controls button,
.timer-settings button {
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    margin: 0 0.5rem;
    cursor: pointer;
    border-radius: 5px;
    border: none;
    transition: opacity 0.2s;
}

.timer-controls button#start-stop-btn {
    background-color: var(--accent-color);
    color: var(--bg-color-light);
}
body.dark-mode .timer-controls button#start-stop-btn {
     color: var(--bg-color-dark);
}

.timer-controls button#reset-btn {
    background-color: var(--label-text);
    color: var(--bg-color);
}


.timer-controls button:hover,
.timer-settings button:hover {
    opacity: 0.9;
}

.timer-settings {
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.timer-settings label {
    font-size: 0.9rem;
    color: var(--label-text);
}

.timer-settings input[type="number"] {
    width: 60px;
    padding: 0.4rem;
    text-align: center;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    background-color: var(--bg-color);
    color: var(--text-color);
}

.timer-settings button#apply-settings-btn {
     background-color: #6c757d;
     color: white;
}


#timer-status {
    margin-top: 1rem;
    font-size: 0.9rem;
    color: var(--label-text);
    min-height: 1.4em;
}

/* Add these rules to hide number input arrows */
.timer-settings input[type="number"]::-webkit-outer-spin-button,
.timer-settings input[type="number"]::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0; /* Removes remaining margin */
}

/* Firefox */
.timer-settings input[type="number"] {
    -moz-appearance: textfield;
}

/* Add these rules */

/* Styling for the new Switch Mode Button */
.timer-controls button#switch-mode-btn {
    background-color: #6c757d; /* Secondary color */
    color: white;
}

/* Styling for the Reset Button container */
.reset-control {
    margin-top: 0.75rem; /* Space above the reset icon */
    line-height: 1; /* Prevent extra vertical space */
}

/* Styling for the Reset Icon Button */
#reset-btn {
    background: none;
    border: none;
    padding: 0;
    font-size: 1.5rem; /* Adjust icon size */
    color: var(--label-text);
    cursor: pointer;
    opacity: 0.7;
    transition: opacity 0.2s ease-in-out;
}

#reset-btn:hover {
    opacity: 1;
}

/* Animation for switching modes */
@keyframes pulse-border {
  0% {
    box-shadow: 0 0 0 0 rgba(102, 191, 255, 0.5);
  }
  50% {
     box-shadow: 0 0 0 6px rgba(102, 191, 255, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(102, 191, 255, 0);
  }
}

.timer-section.switching {
  animation: pulse-border 0.6s ease-out;
}

/* Adjust pulse color for break mode */
.timer-section.break-mode.switching {
    animation-name: pulse-border-break; /* Use a different animation name if colors differ significantly */
}
@keyframes pulse-border-break {
  0% {
    box-shadow: 0 0 0 0 rgba(40, 167, 69, 0.5); /* Green pulse */
  }
  50% {
     box-shadow: 0 0 0 6px rgba(40, 167, 69, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(40, 167, 69, 0);
  }
}