/* main.css — адаптивный базовый стиль для приложения (совместим с Bootstrap 5) */

/* ========== Переменные ========== */
:root {
    --bg-color: #dcdcdc;
    --text-color: #0b0b0b;
    --muted: #ffffff;
    --primary: #4b0082;
    --card-bg: rgba(20, 20, 20, 0.8);
    --radius: 0.9rem;
    --container-max: 1200px;

    /* Типографика */
    --fs-base: clamp(0.95rem, 1rem + 0.2vw, 1.05rem);
    --fs-h1: clamp(1.25rem, 1.2rem + 1.6vw, 2.2rem);
    --fs-h2: clamp(1.05rem, 1rem + 1.0vw, 1.6rem);
    --gap: 1rem;
}

/* ========== Базовые правила ========== */
*,
*::before,
*::after {
    box-sizing: border-box;
}

html, body {
    height: 100%;
    margin: 0;
    font-family: "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
    color: var(--text-color);
    background-color: var(--bg-color);
    font-size: var(--fs-base);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

body {
    padding-top: 80px;
}

/* Ссылки */
a {
    color: var(--primary);
    text-decoration: none;
}

a:hover, a:focus {
    text-decoration: underline;
    outline: none;
}

/* Уважение предпочтений пользователя по анимации */
@media (prefers-reduced-motion: reduce) {
    * {
        transition: none !important;
        animation: none !important;
    }
}

/* ========== Формы и кнопки ========== */
input[type="text"], input[type="date"], input[type="number"], textarea, select {
    width: 300px;
    max-width: 100%;
    padding: 0.45rem 0.6rem;
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(255, 255, 255, 0.03);
    color: var(--text-color);
}

label {
    font-weight: 600;
    display: block;
    margin-bottom: .4rem;
    color: #000103;
}

footer {
    flex-shrink: 0;
    padding: 1rem;
    text-align: center;
    font-size: .95rem;
    background: #0b0b0b;
    color: #9b9b9b;
    border-top: 1px solid rgba(255, 255, 255, 0.03);
}

.report-filter {
    display: flex;
    align-items: flex-end;
    gap: 20px;
    margin-bottom: 25px;
}

.report-filter label {
    display: flex;
    flex-direction: column;
    font-weight: 600;
    font-size: 14px;
}

.report-filter input[type="date"] {
    padding: 6px 10px;
    font-size: 14px;
    border: 1px solid #ccc;
    border-radius: 6px;
}

.report-filter button {
    padding: 8px 18px;
    font-size: 14px;
    border: none;
    background: #369705;
    color: #fff;
    border-radius: 6px;
    cursor: pointer;
}

.report-filter button:hover {
    background: #68fc05;
}

.report-date {
    text-align: center;
    font-size: 30px;
    font-weight: 900;
    margin: 20px 0;
}

/* sticky заголовок всегда к верху окна */
.daily-table thead th {
    position: sticky;
    top: 0; /* всегда 0 относительно окна */
    background: #f6f6f6;
    z-index: 10;
}

.ad-id-cell {
    position: relative;
    cursor: pointer;
    white-space: nowrap;
}

/* Блок tooltip */
.ad-tooltip {
    display: none;
    position: absolute;

    top: 50%;          /* по центру по вертикали */
    left: 100%;        /* сразу справа от ячейки */
    transform: translateY(-50%);

    background: rgba(0, 0, 0, 0.85);
    color: #fff;
    padding: 10px 14px;
    border-radius: 6px;
    font-size: 0.9rem;
    line-height: 1.3;

    z-index: 200;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);

    pointer-events: none;
    white-space: nowrap;
}

/* Треугольник-указатель */
.ad-tooltip::before {
    content: "";
    position: absolute;
    left: -6px;
    top: 50%;
    transform: translateY(-50%);
    border-width: 6px;
    border-style: solid;
    border-color: transparent rgba(0,0,0,0.85) transparent transparent;
}

/* Показ при наведении */
.ad-id-cell:hover .ad-tooltip {
    display: block;
}

.account-name {
    margin-top: 50px;
    color: crimson;
    text-align: center;
}





