/* Laravel-side additions: anchor navigation, auth screen and server feedback.
   Everything else comes from the prototype stylesheets loaded before this. */

/* Sidebar and tab navigation use links, so they inherit the button styling. */
.sidebar nav a,
.admin a {
    width: 100%;
    border: 0;
    background: none;
    text-align: left;
    padding: 10px 11px;
    border-radius: 7px;
    color: #66736d;
    font-size: 13px;
    display: flex;
    gap: 11px;
    align-items: center;
    cursor: pointer;
    margin: 1px 0;
    text-decoration: none;
}

.sidebar nav a span,
.admin a span {
    font-size: 16px;
    width: 17px;
    text-align: center;
}

.sidebar nav a.active,
.admin a.active {
    background: #e8f6ee;
    color: #087c4b;
    font-weight: bold;
}

.sidebar nav a i {
    margin-left: auto;
    background: #fbe9e7;
    color: #db483d;
    border-radius: 10px;
    padding: 2px 7px;
    font-style: normal;
    font-size: 10px;
}

.profile form {
    margin-left: auto;
}

.profile form button {
    border: 0;
    background: none;
    color: #8b9791;
    cursor: pointer;
    font-size: 15px;
}

.tabs a,
.deliveryTabs a,
.accessTabs a,
.viewSwitch a,
.settingsTabs a,
.roleList a,
.intakeMenu a {
    text-decoration: none;
    color: inherit;
    font: inherit;
}

.panelHead a,
.templateCard form,
.notification,
.drawerAction {
    text-decoration: none;
}

.productCard {
    text-decoration: none;
    color: inherit;
    display: block;
}

a.drawerAction {
    display: block;
    text-align: center;
    text-decoration: none;
}

/* Inline forms inside table rows should not disturb the grid. */
.peopleAccessRow form,
.permissionRow form,
.automationRow form,
.serviceRow form,
.settingList form {
    display: contents;
}

/* Server-side validation feedback. */
.formErrors {
    background: #fdecea;
    border: 1px solid #f5c6c0;
    color: #b3271b;
    border-radius: 8px;
    padding: 10px 12px;
    font-size: 11px;
    margin-bottom: 14px;
}

/* Sign-in screen. */
.authShell {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 24px;
    background:
        radial-gradient(circle at 15% 20%, #e4f4ea 0%, transparent 45%),
        radial-gradient(circle at 85% 15%, #eaf6f0 0%, transparent 40%),
        var(--bg);
}

.authCard {
    width: min(420px, 100%);
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 34px 32px;
    box-shadow: 0 24px 60px rgba(13, 38, 27, .12);
}

.authCard .brand {
    padding-bottom: 18px;
}

.authCard h1 {
    font-size: 21px;
    margin: 0 0 6px;
    letter-spacing: -.4px;
}

.authCard > p {
    margin: 0 0 22px;
    color: var(--muted);
    font-size: 12px;
}

.authCard label {
    display: block;
    color: #65736c;
    font-size: 10px;
    letter-spacing: .6px;
    font-weight: bold;
    text-transform: uppercase;
    margin-bottom: 14px;
}

.authCard input[type="email"],
.authCard input[type="password"] {
    width: 100%;
    margin-top: 6px;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 11px 12px;
    font-size: 13px;
    font-family: inherit;
    text-transform: none;
    letter-spacing: 0;
    color: var(--ink);
}

.authCard input:focus {
    outline: 0;
    border-color: #159a61;
}

.authRemember {
    display: flex;
    align-items: center;
    gap: 8px;
    text-transform: none;
    letter-spacing: 0;
    font-weight: normal;
    font-size: 11px;
    color: var(--muted);
}

.authCard button {
    width: 100%;
    background: #158b59;
    color: #fff;
    border: 0;
    border-radius: 8px;
    padding: 12px;
    font-size: 13px;
    font-weight: bold;
    cursor: pointer;
    margin-top: 4px;
}

.authHint {
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid var(--line);
    font-size: 10px;
    color: var(--muted);
    line-height: 1.7;
}

.authHint b {
    color: var(--ink);
}

/* The prototype declares .modalLayer/.overlay display with !important, which
   beats the browser default for [hidden]. Restore it so layers start closed. */
.modalLayer[hidden],
.overlay[hidden] {
    display: none !important;
}

/* Buttons size to their content, so these row buttons need an explicit width
   to fill their panel the way the design intends. */
.attentionRow,
.projectRow,
.activityRow,
.healthRow {
    width: 100%;
}

/* ---------------------------------------------------------------------------
   Tab and list navigation is server-side, so the prototype's `button` rules
   are mirrored here for the equivalent anchors. Declarations match 1:1.
   --------------------------------------------------------------------------- */

.tabs a {
    border: 0;
    background: transparent;
    color: #6f7c76;
    padding: 8px 11px;
    border-radius: 6px;
    font-size: 10px;
    cursor: pointer;
    white-space: nowrap;
}

.tabs a.selected {
    background: #fff;
    color: #128755;
    font-weight: bold;
    box-shadow: 0 1px 3px #ced9d2;
}

.tabs a b {
    background: #eaeeec;
    border-radius: 9px;
    padding: 1px 6px;
    margin-left: 5px;
    font-size: 9px;
}

.viewSwitch a {
    border: 1px solid var(--line);
    background: #fff;
    padding: 7px 10px;
    color: #74817a;
    font-size: 9px;
    cursor: pointer;
}

.viewSwitch a:first-of-type {
    border-radius: 7px 0 0 7px;
}

.viewSwitch a:last-of-type {
    border-radius: 0 7px 7px 0;
}

.viewSwitch a.selected {
    background: #e7f5ed;
    color: #108352;
    border-color: #bfe3cf;
    font-weight: bold;
}

.deliveryTabs a {
    border: 0;
    background: transparent;
    padding: 10px 11px;
    color: #718078;
    font-size: 11px;
    white-space: nowrap;
    border-bottom: 2px solid transparent;
}

.deliveryTabs a.selected {
    color: #128955;
    border-bottom-color: #128955;
    font-weight: 800;
}

.deliveryTabs a b {
    background: #edf3f0;
    border-radius: 10px;
    padding: 2px 6px;
    margin-left: 5px;
}

.accessTabs a {
    border: 0;
    background: none;
    padding: 10px 13px;
    color: #718078;
    font-size: 10px;
}

.accessTabs a.selected {
    color: #128554;
    border-bottom: 2px solid #128554;
    font-weight: bold;
}

.accessTabs a b {
    background: #edf3f0;
    border-radius: 10px;
    padding: 2px 6px;
    margin-left: 5px;
}

.intakeMenu a {
    display: block;
    width: 100%;
    border: 0;
    background: #fff;
    text-align: left;
    padding: 12px;
    border-radius: 7px;
    cursor: pointer;
}

.intakeMenu a.selected {
    background: #e8f6ee;
    color: #0f8151;
}

.intakeMenu a b,
.intakeMenu a small {
    display: block;
}

.intakeMenu a b {
    font-size: 11px;
}

.intakeMenu a small {
    font-size: 8px;
    color: #87948e;
    margin-top: 4px;
}

.settingsTabs a {
    width: 100%;
    border: 0;
    background: #fff;
    border-radius: 7px;
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 11px;
    text-align: left;
    color: #65736c;
    font-size: 10px;
    cursor: pointer;
}

.settingsTabs a.selected {
    background: #e7f5ed;
    color: #118554;
    font-weight: bold;
}

.settingsTabs a span {
    font-size: 14px;
}

.settingsTabs a b {
    margin-left: auto;
    background: #edf2ef;
    padding: 2px 6px;
    border-radius: 9px;
    font-size: 8px;
}

.roleList > a {
    width: 100%;
    border: 0;
    background: #fff;
    display: flex;
    gap: 9px;
    align-items: center;
    text-align: left;
    padding: 11px;
    border-radius: 7px;
}

.roleList > a.selected {
    background: #e8f6ee;
}

.roleList > a > i {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #89958f;
}

.roleList > a > i.green { background: #18a164; }
.roleList > a > i.blue { background: #5480c7; }
.roleList > a > i.amber { background: #d58b23; }
.roleList > a > i.purple { background: #855eb1; }

.roleList > a span {
    flex: 1;
}

.roleList > a b,
.roleList > a small {
    display: block;
    font-size: 10px;
}

.roleList > a small {
    font-size: 8px;
    color: #89958f;
    margin-top: 3px;
}

@media (max-width: 800px) {
    .intakeMenu a { min-width: 150px; }
    .settingsTabs a { min-width: 140px; }
    .roleList > a { min-width: 160px; }
}
