@import url('https://fonts.googleapis.com/css2?family=PT+Sans:ital,wght@0,400;0,700;1,400;1,700&family=Play:wght@400;700&family=Raleway:ital,wght@0,100..900;1,100..900&display=swap');

:root {
    --accent: #7d39eb;
    --accent-dark: #5026a7;
    --bg: #ffffff;
    --text: #1f1f1f;
    --muted: #6f6f6f;
    --shadow: 0 2px 10px rgba(0,0,0,0.12);
    --radius: 16px;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

body {
    font-family: "Raleway", sans-serif;
    background: var(--bg);
    color: var(--text);
    margin: 0;
    min-height: 100dvh;
}

/* HEADER */
header {
    background: #fff;
    padding: 10px clamp(12px, 3vw, 32px);
    margin-bottom: 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 10;
}

header img.logo,
header img {
    height: clamp(38px, 5vw, 50px);
    width: auto;
}

nav a {
    text-decoration: none;
    font-size: clamp(14px, 1.8vw, 16px);
    color: var(--text);
}

nav a:hover {
    color: var(--accent);
}

/* LAYOUT */
main {
    width: min(1200px, 100% - 2rem);
    margin-inline: auto;
    padding-bottom: 24px;
}

.content {
    width: 100%;
}

/* SERVICES */
.services-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: clamp(12px, 2vw, 20px);
    align-items: stretch;
}

.service-block {
    background: #fff;
    border-radius: var(--radius);
    padding: clamp(28px, 4vw, 28px);
    box-shadow: var(--shadow);
    cursor: pointer;
    transition: transform .2s ease, box-shadow .2s ease;
    min-height: 180px;
}

.service-block:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.12);
}

.service-block h2 {
    margin: 0 0 10px;
    color: var(--accent);
    font-size: clamp(18px, 2.2vw, 24px);
}

.service-block p {
    margin: 0;
    color: #404040;
    line-height: 1.45;
    font-size: clamp(14px, 1.8vw, 16px);
}

/* NO ROLE BLOCK */
.no-role-block {
    width: min(680px, 100%);
    min-height: 220px;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    gap: 16px;
    font-size: clamp(15px, 1.8vw, 18px);
    border-radius: 18px;
    box-shadow: var(--shadow);
    padding: clamp(20px, 3vw, 36px);
    margin: clamp(20px, 8vh, 80px) auto 0;
    background: #7b43ff;
    color: white;
    text-align: center;
}

.no-role-block p {
    width: min(100%, 560px);
    margin: 0;
    text-align: center;
    line-height: 1.5;
}

.no-role-block h2 {
    margin: 0;
    line-height: 1.25;
}

/* LOGIN PAGE */
.login-page {
    min-height: 100dvh;
    display: grid;
    place-items: center;
    padding: 20px;
}

.login-block {
    width: min(420px, 100%);
    background: #fff;
    border-radius: 20px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.1);
    padding: clamp(20px, 3vw, 32px);
}

.signin {
    margin: 0 0 24px;
    font-size: clamp(26px, 5vw, 34px);
    font-weight: 700;
    text-align: center;
    color: var(--accent);
}

.error {
    color: #d31d1d;
    font-size: 14px;
    margin: 0 0 12px;
}

.login-block input[type="text"],
.login-block input[type="password"] {
    display: block;
    width: 100%;
    margin: 0 0 12px;
    border-radius: 12px;
    border: none;
    background: #e9efff;
    padding: 12px 14px;
    font-size: 16px;
    font-family: inherit;
    outline: none;
}

.login-block input:focus {
    box-shadow: 0 0 0 2px rgba(125, 57, 235, 0.25);
}

.login-block button[type="submit"] {
    width: 100%;
    background: var(--accent);
    border-radius: 12px;
    border: none;
    color: #fff;
    font-weight: 600;
    font-size: 16px;
    padding: 12px 14px;
    margin-top: 8px;
    cursor: pointer;
    transition: background .2s;
}

.login-block button[type="submit"]:hover {
    background: var(--accent-dark);
}

.switch-link {
    display: block;
    text-align: center;
    margin-top: 16px;
    color: var(--accent);
    text-decoration: none;
    font-size: 15px;
}

.switch-link:hover {
    text-decoration: underline;
}

/* MOBILE TWEAKS */
@media (max-width: 640px) {
    header {
        padding: 10px 12px;
    }

    main {
        width: min(1200px, 100% - 1rem);
    }

    .service-block {
        min-height: 150px;
    }
}