:root {
  --sidebar-bg: #f5f7fa;
  --sidebar-text: #333;
  --sidebar-active: #e1e6f0;
  --primary: #1e88e5;
  --success: #43a047;
  --danger: #e53935;
  --text-dark: #212121;
  --bg-card: #ffffff;
  --border-radius: 8px;
  --shadow: rgba(0,0,0,0.1);
}

body {
  display: flex;
  color: var(--text-dark);
  height: 100vh;
  background: #eef2f5;
}

.sidebar {
  width: 220px;
  background: var(--sidebar-bg);
  padding: 20px;
  border-right: 1px solid #ddd;
}

.sidebar__logo {
  font-size: 1.4rem;
  font-weight: bold;
  margin-bottom: 1.5rem;
}

.sidebar__nav a {
  display: flex;
  align-items: center;
  padding: 10px 12px;
  margin-bottom: 8px;
  text-decoration: none;
  color: var(--sidebar-text);
  border-radius: var(--border-radius);
  transition: background .2s;
}

.sidebar__nav a i { width: 20px; }

.sidebar__nav a:hover,
.sidebar__nav a.active {
  background: var(--sidebar-active);
  font-weight: bold;
}

.main-content {
  flex: 1;
  padding: 30px;
  overflow-y: auto;
}

.main-content__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.main-content__header h1 {
  font-size: 1.8rem;
  margin-bottom: 20px;
}

.theme-toggle {
  background: none;
  border: none;
  font-size: 1.4rem;
  cursor: pointer;
}

.card {
  background: var(--bg-card);
  border-radius: var(--border-radius);
  box-shadow: 0 2px 8px var(--shadow);
  padding: 30px;
  margin-bottom: 30px;
}

/* Temporizador */
.timer-card .progress-circle {
  position: relative;
  width: 200px; height: 200px;
  margin: 0 auto 20px;
}

.progress-circle svg {
  transform: rotate(-90deg);
  width: 100%; height: 100%;
}

.progress-circle circle {
  fill: none;
  stroke: #eee;
  stroke-width: 20;
}

.progress-circle circle:nth-child(1) {
  stroke-dasharray: 565.48;
  stroke-dashoffset: 0;
  transition: stroke-dashoffset 1s linear;
  stroke: var(--primary);
}

.timer-display {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  font-size: 2.5rem;
  color: #222;
}

/* Controles */
.timer-controls {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-bottom: 20px;
}

.timer-controls button {
  flex: 1;
  padding: 10px;
  font-size: 0.9rem;
  border: none;
  border-radius: var(--border-radius);
  cursor: pointer;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
}

#add   { background: var(--success); }
#start { background: var(--primary); }
#reset { background: var(--danger); }

.timer-controls button i {
  margin-right: 6px;
}

/* Costo estimado */
.cost-display {
  text-align: center;
  font-size: 0.9rem;
}

.cost-display label {
  margin-right: 8px;
}

.cost-display select {
  padding: 4px 8px;
  border-radius: var(--border-radius);
}

/* Formulario */
.profile-form h2 {
  font-size: 1.2rem;
  margin-bottom: 16px;
}

.profile-form form {
  display: flex;
  flex-direction: column;
}

.profile-form .form-group {
  display: flex;
  flex-direction: column;
  margin-bottom: 12px;
}

.profile-form label {
  margin-bottom: 4px;
  font-size: 0.9rem;
}

.profile-form input {
  padding: 8px 12px;
  font-size: 0.95rem;
  border: 1px solid #ccc;
  border-radius: var(--border-radius);
  transition: border-color .2s;
}

.profile-form input:focus {
  border-color: var(--primary);
}

.btn-submit {
  align-self: flex-start;
  padding: 10px 20px;
  font-size: 0.95rem;
  background: var(--primary);
  color: #fff;
  border: none;
  border-radius: var(--border-radius);
  cursor: pointer;
  display: flex;
  align-items: center;
}

.btn-submit i { margin-right: 6px; }

.btn-export {
  margin-top: 12px;
  padding: 10px 20px;
  background: var(--primary);
  color: #fff;
  border: none;
  border-radius: var(--border-radius);
  cursor: pointer;
  font-weight: bold;
}

/* Historial */
.history h2 {
  font-size: 1.2rem;
  margin-bottom: 12px;
}

.history ul {
  list-style: none;
  max-height: 200px;
  overflow-y: auto;
  padding-left: 0;
}

.history li {
  padding: 8px 0;
  border-bottom: 1px solid #f0f0f0;
  font-size: 0.9rem;
}

.btn-clear {
  margin-top: 12px;
  padding: 8px 16px;
  background: #999;
  color: #fff;
  border: none;
  border-radius: var(--border-radius);
  cursor: pointer;
}

/* Modo oscuro */
body.dark {
  background: #1e1e1e;
  color: #ddd;
}
body.dark .sidebar { background: #2a2a2a; }
body.dark .card { background: #333; box-shadow: 0 2px 8px rgba(0,0,0,0.6); }
body.dark input,
body.dark select {
  background: #444;
  border-color: #555;
  color: #ddd;
}
