/*
 * Hive theme on top of Filament: honey amber and ink navy (the colours of the logo).
 * The panel has no Tailwind build of its own, so this file is loaded after Filament's stylesheet.
 */
:root {
    --hive-honey: #f5a800;
    --hive-honey-light: #ffb81f;
    --hive-honey-deep: #d98600;
    --hive-ink: #1d2330;
    --hive-hex-stroke: rgba(245, 168, 0, 0.16);
}

.dark {
    --hive-hex-stroke: rgba(245, 168, 0, 0.09);
}

body {
    font-feature-settings: 'cv11', 'ss01', 'calt';
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

/* Numbers line up in tables and statistics. */
.fi-ta-cell,
.fi-ta-summary,
.fi-wi-stats-overview-stat-value {
    font-variant-numeric: tabular-nums;
}

h1.fi-header-heading,
.fi-simple-header-heading {
    font-weight: 650;
    letter-spacing: -0.02em;
}

/* Solid primary buttons: honey with ink text, as readable as the logo. */
.fi-btn.fi-color-primary:not(.fi-outlined):not(label):not([aria-pressed]) {
    background-color: var(--hive-honey);
    color: var(--hive-ink);
    font-weight: 600;
    border-radius: 0.5rem;
    box-shadow: inset 0 -1px 0 rgb(29 35 48 / 0.16), 0 1px 2px rgb(29 35 48 / 0.12);
    transition: background-color 0.15s ease, box-shadow 0.15s ease, transform 0.05s ease;
}

.fi-btn.fi-color-primary:not(.fi-outlined):not(label):not([aria-pressed]):hover:not(.fi-disabled):not([disabled]) {
    background-color: var(--hive-honey-light);
    color: var(--hive-ink);
}

.fi-btn.fi-color-primary:not(.fi-outlined):not(label):not([aria-pressed]):active:not(.fi-disabled):not([disabled]) {
    background-color: var(--hive-honey-deep);
    transform: translateY(1px);
}

.fi-btn.fi-color-primary:not(.fi-outlined):not(label):not([aria-pressed]) .fi-icon,
.fi-btn.fi-color-primary:not(.fi-outlined):not(label):not([aria-pressed]) svg {
    color: var(--hive-ink);
}

/* All other buttons share the same shape and weight. */
.fi-btn {
    border-radius: 0.5rem;
    font-weight: 600;
}

.fi-btn:not(.fi-color-primary):not(.fi-outlined):not(label) {
    box-shadow: 0 1px 2px rgb(29 35 48 / 0.08);
}

/* Fields and cards. */
.fi-input-wrp,
.fi-fo-select .fi-input-wrp {
    border-radius: 0.5rem;
}

.fi-section,
.fi-ta-ctn,
.fi-wi-stats-overview-stat {
    border-radius: 0.75rem;
}

/* Active menu item: a honey tint instead of plain grey. */
.fi-sidebar-item.fi-active > .fi-sidebar-item-btn {
    background-color: #fff3d1;
}

.fi-sidebar-item.fi-active > .fi-sidebar-item-btn .fi-sidebar-item-label,
.fi-sidebar-item.fi-active > .fi-sidebar-item-btn .fi-icon {
    color: #8f4f0c;
    font-weight: 600;
}

.dark .fi-sidebar-item.fi-active > .fi-sidebar-item-btn {
    background-color: rgb(245 168 0 / 0.14);
}

.dark .fi-sidebar-item.fi-active > .fi-sidebar-item-btn .fi-sidebar-item-label,
.dark .fi-sidebar-item.fi-active > .fi-sidebar-item-btn .fi-icon {
    color: #ffcd4d;
}

.fi-sidebar-group-label {
    letter-spacing: 0.06em;
    text-transform: uppercase;
    font-size: 0.7rem;
    font-weight: 600;
}

/* Login page: a faint honeycomb behind the card. */
.fi-simple-layout {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='52' height='90' viewBox='0 0 52 90'%3E%3Cg fill='none' stroke='%23f5a800' stroke-opacity='0.22' stroke-width='1.5'%3E%3Cpath d='M0 -30 L26 -15 L26 15 L0 30 L-26 15 L-26 -15 Z'/%3E%3Cpath d='M52 -30 L78 -15 L78 15 L52 30 L26 15 L26 -15 Z'/%3E%3Cpath d='M26 15 L52 30 L52 60 L26 75 L0 60 L0 30 Z'/%3E%3Cpath d='M0 60 L26 75 L26 105 L0 120 L-26 105 L-26 75 Z'/%3E%3Cpath d='M52 60 L78 75 L78 105 L52 120 L26 105 L26 75 Z'/%3E%3C/g%3E%3C/svg%3E");
    background-size: 52px 90px;
}

.dark .fi-simple-layout {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='52' height='90' viewBox='0 0 52 90'%3E%3Cg fill='none' stroke='%23f5a800' stroke-opacity='0.1' stroke-width='1.5'%3E%3Cpath d='M0 -30 L26 -15 L26 15 L0 30 L-26 15 L-26 -15 Z'/%3E%3Cpath d='M52 -30 L78 -15 L78 15 L52 30 L26 15 L26 -15 Z'/%3E%3Cpath d='M26 15 L52 30 L52 60 L26 75 L0 60 L0 30 Z'/%3E%3Cpath d='M0 60 L26 75 L26 105 L0 120 L-26 105 L-26 75 Z'/%3E%3Cpath d='M52 60 L78 75 L78 105 L52 120 L26 105 L26 75 Z'/%3E%3C/g%3E%3C/svg%3E");
}

/*
 * "Hive" theme: a third look next to light and dark. The left column (menu) is ink navy, the right
 * column (content) a pale honey tint. It is switched on from the user menu (class `hive-theme` on <html>)
 * and only applies in light mode, so choosing "dark" in the Filament switcher still gives the dark look.
 */
html.hive-theme:not(.dark) .fi-body {
    background-color: #fbf6e8;
}

html.hive-theme:not(.dark) .fi-topbar {
    background-color: #fffaf0;
    box-shadow: 0 1px 0 rgb(29 35 48 / 0.08);
    --tw-ring-shadow: 0 0 #0000;
}

html.hive-theme:not(.dark) .fi-sidebar {
    background-color: #1d2330;
    color: #eef0f4;
    --tw-ring-shadow: 0 0 #0000;
    box-shadow: none;
}

html.hive-theme:not(.dark) .fi-sidebar-header {
    background-color: transparent;
    box-shadow: none;
    border-bottom: 1px solid rgb(255 255 255 / 0.08);
}

html.hive-theme:not(.dark) .fi-sidebar .fi-logo {
    color: #f4f1e8;
}

html.hive-theme:not(.dark) .fi-sidebar-item-label {
    color: #c9cfdb;
}

html.hive-theme:not(.dark) .fi-sidebar-item-btn > .fi-icon,
html.hive-theme:not(.dark) .fi-sidebar-group-label,
html.hive-theme:not(.dark) .fi-sidebar-group-collapse-btn,
html.hive-theme:not(.dark) .fi-sidebar-group-btn .fi-icon {
    color: #8f98aa;
}

html.hive-theme:not(.dark) .fi-sidebar-item-btn:hover {
    background-color: rgb(255 255 255 / 0.07);
}

html.hive-theme:not(.dark) .fi-sidebar-item-btn:hover .fi-sidebar-item-label {
    color: #ffffff;
}

html.hive-theme:not(.dark) .fi-sidebar-item.fi-active > .fi-sidebar-item-btn {
    background-color: rgb(245 168 0 / 0.16);
}

html.hive-theme:not(.dark) .fi-sidebar-item.fi-active > .fi-sidebar-item-btn .fi-sidebar-item-label,
html.hive-theme:not(.dark) .fi-sidebar-item.fi-active > .fi-sidebar-item-btn .fi-icon {
    color: #ffcd4d;
}
