:root {
  --primary-color: #0066ff;
  --secondary-color: #001133;
  --accent-color: #ff6600;
  --light-bg: #f5f8ff;
  --dark-text: #333;
  --light-text: #fff;
  --border-radius: 8px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background-color: var(--light-bg);
  color: var(--dark-text);
}

header {
  background: var(--secondary-color);
  color: var(--light-text);
  padding: 20px;
  text-align: center;
  margin-bottom: 20px; /* чуть больше от шапки */
}
header h1 {
  margin: 0;
}

/* Контейнер без лишних паддингов, только центрирование */
.container {
  max-width: 800px;
  margin: 40px auto;
  padding: 0 20px;
}

/* ==== Карточки ==== */
.card {
  background: #fff;
  border-radius: var(--border-radius);
  box-shadow: 0 4px 6px rgba(0,0,0,0.1);
  overflow: hidden;
  margin-bottom: 40px;   /* расстояние между карточками */
  padding: 20px;         /* вот это добавляет по 20px отступов со всех сторон */
}

/* Внутренние отступы уже здесь */
.card-inner {
  padding: 40px 20px;
}

/* ==== Tabs ==== */
.tabs {
  display: flex;
  background: #fff;
  border-bottom: 1px solid #ddd;
  margin: 0;
  padding: 0;            /* убрали padding сверху, всё в .card-inner */
}
.tab {
  padding: 10px 20px;
  cursor: pointer;
  border: 1px solid transparent;
  border-bottom: none;
  border-radius: var(--border-radius) var(--border-radius) 0 0;
  margin-right: 5px;
  background: #fff;
  transition: background .2s;
}
.tab:hover {
  background: rgba(0,102,255,0.1);
}
.tab.active {
  background: var(--primary-color);
  color: var(--light-text);
  border: 1px solid #ddd;
  border-bottom: none;
}

/* ==== Секции ==== */
.section {
  display: none;
}
.section.active {
  display: block;
}

/* ==== Формы ==== */
.form-group {
  margin-bottom: 15px;
}
label {
  display: block;
  margin-bottom: 5px;
  font-weight: bold;
  margin-top: 20px;
}
textarea,
input[type="text"],
input[type="password"] {
  width: 100%;
  padding: 10px;
  border: 1px solid #ddd;
  border-radius: var(--border-radius);
  font-family: inherit;
}

/* ==== Кнопки ==== */
.button-group {
  display: flex;
  gap: 10px;
  margin-top: 10px;
}
.button {
  background: var(--primary-color);
  color: var(--light-text);
  border: none;
  padding: 10px 20px;
  border-radius: var(--border-radius);
  cursor: pointer;
  transition: background .2s;
  flex: none;
  width: auto;
  max-width: 200px;
}
.button:hover {
  background: var(--accent-color);
}

/* ==== Результаты ==== */
.result {
  background-color: #e6f0ff;
  border-radius: var(--border-radius);
  padding: 20px;
  margin-top: 20px;
}
.result h2 {
  margin: 0 0 12px;
  font-size: 1.25rem;
}
.result h3 {
  margin: 16px 0 8px;
  font-size: 1rem;
  font-weight: bold;
}
.result .line {
  display: flex;
  justify-content: space-between;
  margin: 6px 0;
  font-size: 0.95rem;
}
.result .total {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  margin-top: 16px;
  font-size: 1.1rem;
  font-weight: bold;
}
.result .total .amount {
  color: var(--accent-color);
  margin: 0 12px 0 4px;
}
.result .btn-copy {
  background-color: var(--primary-color);
  color: #fff;
  border: none;
  padding: 6px 14px;
  border-radius: var(--border-radius);
  cursor: pointer;
  font-size: 0.9rem;
}
.result .btn-copy:hover {
  background-color: var(--accent-color);
}

/* ==== Canned Reply (вторая карточка) ==== */
.canned textarea {
  width: 100%;
  height: 120px;
  resize: vertical;
}
.canned .btn-copy {
  background: var(--primary-color);
  color: var(--light-text);
  border: none;
  padding: 10px 20px;
  border-radius: var(--border-radius);
  cursor: pointer;
  transition: background .2s;
  margin-top: 20px;
}
.canned .btn-copy:hover {
  background: var(--accent-color);
}

/* ==== Toast ==== */
#toast {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: rgba(0,0,0,0.8);
  color: #fff;
  padding: 10px 16px;
  border-radius: var(--border-radius);
  font-size: 0.9rem;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.3s ease, transform 0.3s ease;
  z-index: 10000;
  pointer-events: none;
}
#toast.show {
  opacity: 1;
  transform: translateY(0);
}

/* ==== Login Page ==== */
.login-title {
  text-align: center;
  margin-bottom: 20px;
  font-size: 1.25rem;
}


