/* Minimalistic and Modern CSS for Psychological Assistance Website (2025) */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');
@import url("https://fonts.googleapis.com/css2?family=Montserrat:ital,wght@0,100..900;1,100..900&display=swap");
@import url("https://fonts.googleapis.com/css2?family=Racing+Sans+One&display=swap");

:root {
    --primary-color: #00AC48;
    --accent-color: #4e72ff;
    --background-start: #87CEEB;
    --background-end: #E0F6FF;
    --text-color: #111111;
    --white: #ffffff;
    --shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "Montserrat", sans-serif;
    color: var(--text-color);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow-x: hidden;
    overflow-y: auto;
    max-width: 100vw;
}

body.contentbody {
  background-image: url('../images/bg.jpg');
  background-size: 100% auto;
  background-position: top center;
  background-repeat: no-repeat;
  background-color: #9dd8ea;
}

h1, h2, h3, h4 {
  font-family: "Racing Sans One", sans-serif;
  color: #099A60;
}

h1 {
  margin-bottom: 50px;
  font-size: 30px;
}

h2 {
  font-size: 26px;
}

h3 {
  font-size: 24px;
}

h4 {
  font-size: 22px;
}

.notification-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
}
.notification {
    background-color: #007bff;
    color: white;
    padding: 10px 20px;
    margin-bottom: 10px;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
    cursor: pointer;
}
.notification:hover {
    background-color: #0056b3;
}
.alert-container {
    margin-top: 20px;
}
.alert {
    background-color: #28a745;
    color: white;
    padding: 10px;
    margin-bottom: 10px;
    border-radius: 5px;
}
.alert-error {
    background-color: #dc3545;
}

.text-right {
  text-align: right;
}

.background-clouds {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: linear-gradient(to bottom, var(--background-start), var(--background-end));
    touch-action: none;
}

.modal#forwardModal {
  background: rgba(0,0,0,.4);
  backdrop-filter: blur(5px);
}

.modal#forwardModal .modal-content {
  margin-top: 100px;
}

.modal#forwardModal .modal-content .close {
  position: absolute;
  right: 10px;
  top: 10px;
}

.modal#forwardModal .modal-content .close {
  position: absolute;
  right: 10px;
  top: 10px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: none;
}

main.container {
    z-index: 10;
    max-width: 900px;
    margin: 2rem auto;
    padding: 0 1rem;
    width: 100%;
    overflow-x: hidden;
}

header, footer {
    z-index: 100;
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
}

header {
  background: rgba(255,255,255,.7);
  padding: 1rem 2rem;
  position: sticky;
  top: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  backdrop-filter: blur(5px);
}

header a {
    color: var(--primary-color);
    text-decoration: none;
    font-size: 1.5rem;
    font-weight: 600;
}

.main-logo {
    height: 40px; /* Adjust as needed */
    vertical-align: middle;
}

.navbar-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-color);
}

.navbar-menu {
    display: flex;
    gap: 1.5rem;
}

.navbar-menu a {
    color: var(--text-color);
    text-decoration: none;
    font-weight: 500;
    font-size: 1rem;
    transition: color 0.3s ease, transform 0.3s ease;
}

.navbar-menu a:hover {
    color: var(--primary-color);
    transform: translateY(-2px);
}

.language-switcher {
    position: relative;
}

.current-username, .language-switcher {
  display: inline-block;
}

.current-username {
  font-style: italic;
  font-size: 14px;
  margin-right: 15px;
}

.create_request_wrapper {
  margin-bottom: 30px;
  text-align: right;
}

.lang-dropdown {
    background: var(--white);
    border: 1px solid #e0e0e0;
    color: var(--text-color);
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-size: 0.9rem;
    cursor: pointer;
    appearance: none;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.lang-dropdown:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 8px rgba(74, 144, 226, 0.2);
}

.lang-dropdown option {
    background: var(--white);
    color: var(--text-color);
}

.hero {
    text-align: center;
    margin: 4rem 0;
    animation: fadeIn 1s ease-out;
}

.hero h1 {
    font-size: 2.5rem;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 0.5rem;
}

.hero p {
    font-size: 1.2rem;
    color: var(--text-color);
    opacity: 0.7;
}

.request-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
}

.request-card {
    background: var(--white);
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: var(--shadow);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.request-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

.request-card a {
    text-decoration: none;
    color: inherit;
}

.request-card h3 {
  font-size: 1.2rem;
  font-weight: 500;
  color: var(--primary-color);
  margin-bottom: 0.5rem;
  width: 85%;
  display: inline-block;
  vertical-align: top;
}

.status-container {
    display: inline-block;
  width: 14%;
  text-align: center;
}

.request-card .status {
  font-size: 0.8rem;
  padding: 0.25rem 0.75rem;
  border-radius: 17px;
  display: inline-block;
  margin-bottom: 0.5rem;
  width: 100%;
}

.request-action-buttons-container {
  text-align: right;
}

.request-card .status.current-state { background-color: #dfdfdf; }

.status-green { background: #a3e635; color: var(--text-color); }
.status-yellow { background: #f4a261; color: var(--white); }
.status-red { background: #e63946; color: var(--white); }

.request-card .date {
    font-size: 0.85rem;
    color: var(--text-color);
    opacity: 0.6;
}

.no-requests {
    text-align: center;
    padding: 2rem;
    background: var(--white);
    border-radius: 12px;
    box-shadow: var(--shadow);
}

.no-requests .material-icons {
    font-size: 2rem;
    color: var(--accent-color);
    margin-bottom: 0.5rem;
}

.login-prompt {
    text-align: center;
    padding: 2rem;
    background: var(--white);
    border-radius: 12px;
    box-shadow: var(--shadow);
}

.login-prompt .material-icons {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.login-prompt p {
    margin-bottom: 1rem;
}

.btn {
    background: var(--primary-color);
    color: var(--white);
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: transform 0.3s ease, box-shadow 0.3s ease, background 0.3s ease;
    touch-action: manipulation;
    margin-right: 0.5rem;
    margin-bottom: 0.5rem;
}

.btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(74, 144, 226, 0.3);
    background: #3a80d2;
}

.btn-primary {
    background: var(--primary-color);
}

.btn-primary:hover {
    background: #4e72ff;
    box-shadow: 0 4px 12px rgba(158, 121, 103, 0.3);
}

.btn-danger {
    background: #e63946;
}

.btn-danger:hover {
    background: #d32f2f;
    box-shadow: 0 4px 12px rgba(230, 57, 70, 0.3);
}

.btn-warning {
    background: #f4a261;
    color: var(--white);
}

.btn-warning:hover {
    background: #e69138;
    box-shadow: 0 4px 12px rgba(244, 162, 97, 0.3);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-control {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    background: var(--white);
    color: var(--text-color);
    font-size: 1rem;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
    touch-action: manipulation;
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 8px rgba(74, 144, 226, 0.2);
}

.form-control::placeholder {
    color: rgba(51, 51, 51, 0.5);
}

textarea.form-control {
    resize: vertical;
    min-height: 100px;
}

select.form-control {
    appearance: none;
    background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="%23333333"><path d="M7 10l5 5 5-5H7z"/></svg>') no-repeat right 0.75rem center/16px;
}

.table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow);
}

.table th {
    background: var(--accent-color);
    color: var(--white);
    padding: 1rem;
    font-weight: 500;
    text-align: left;
}

.table td {
    padding: 1rem;
    border-bottom: 1px solid #e0e0e0;
}

.table tr:last-child td {
    border-bottom: none;
}

.table tr:nth-child(even) {
    background: #f9f9f9;
}

.table a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

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

.requests-table {
  margin-top: 30px;
}

.submitbutton-wrapper {
  margin: 0 !important;
}

.submitbutton-wrapper button {
  margin-top: 25px;
}

.request-creation-date strong, .request-meta strong {
  display: block;
  font-size: 12px;
  color: #999;
}

.request-meta p {font-size: 16px;}

.request-meta {
  margin-bottom: 40px;
}

.chat {
    background: var(--white);
    padding: 1.5rem;
    border-radius: 12px;
    overflow-y: auto;
    margin-bottom: 1.5rem;
    box-shadow: var(--shadow);
}

.message {
    margin-bottom: 1rem;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    background: #f9f9f9;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.message.message-pilot {
  border-left: 3px solid #4e72ff;
}

.message.message-peer {
  border-left: 3px solid #00ac48;
}

.message.message-psychologist {
  border-left: 3px solid #cc0a2f;
}

.message.initial-message, .message.initial-message .message {
  background-color: #eaeaea;
}

.open-requests-wrapper {
  margin-bottom: 30px;
}

.message.initial-message {
    border-left: 3px solid #4e72ff !important;
}

.message strong {
    color: var(--primary-color);
    font-weight: 500;
    font-size: 13px;
}

.request-card .status-container {
  display:inline-block;
  width:auto;
}

.message.message-pilot strong {
    color: #4e72ff;
}

.message.message-peer strong {
    color: #00ac48;
}

.message.message-psychologist strong {
    color: #cc0a2f;
}

.message-contacts {
  text-align: right;
}

.message .date {
  font-size: 12px;
  color: #555;
}

.alert-container {
    margin-bottom: 1.5rem;
}

.alert {
    background: var(--white);
    color: var(--text-color);
    padding: 1rem;
    border-radius: 8px;
    box-shadow: var(--shadow);
    border-left: 4px solid var(--primary-color);
}

.message .message-body p.message {
  border: none;
  box-shadow: none;
  font-size: 15px;
  margin: 10px;
}

.open-requests-wrapper .request-card {
    position: relative;
}

.open-requests-wrapper .request-card .status-container {
position: absolute;
    right:10px;
    top:10px;
}

.open-requests-wrapper .request-card h3, .open-requests-wrapper .request-card p.date {
    width: calc(100% - 120px)
}



footer {
    background: var(--white);
    color: var(--text-color);
    text-align: left;
    margin-top: auto;
    box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.1);
}

.footer-top {
  background-color: #1E465E;
  padding: 70px 0 20px 0;
}

.footer-top a{
    text-decoration: none;
}

.footer-bottom {
  padding: 50px 0;
  background-color: #000;
}

.footer-logo {
  margin-bottom: 30px;
}

.footer-text {
  font-weight: 400;
  font-size: 13px;
  margin-bottom: 5px;
  color: #BCBCBC;
  line-height: 125%;
}

.footer-block {
  margin-bottom: 55px;
}

.footer-label {
  font-weight: 400;
  font-size: 13px;
  color: #BCBCBC;
  line-height: 125%;
  margin-bottom: 5px;
}

.footer-value {
  font-weight: 400;
  font-size: 20px;
  color: #fff;
  line-height: 125%;
}

.footer-value a {
  font-weight: 400;
  font-size: 20px;
  color: #fff;
  line-height: 125%;
  border-bottom: 0;
  transition: all ease-in-out .2s;
}

.footer-value a:hover {
  color: #00E98C;
}

.footer-title {
  font-family: "Racing Sans One", sans-serif;
  font-weight: 400;
  font-size: 24px;
  color: #00E98C;
  line-height: 125%;
  margin-bottom: 65px;
}

.copyright, .footer-made {
  font-weight: 400;
  font-size: 12px;
  color: #fff;
  line-height: 150%;
}

.footer-made a {
  color: #fff;
  border-bottom: 1px solid #fff;
}

.footer-menu ul {
  display: flex;
  margin-bottom: 0;
  gap: 20px;
}

.footer-menu ul li { margin-bottom: 0; }

.footer-menu ul li a {
  font-weight: 400;
  font-size: 12px;
  color: #fff;
  line-height: 150%;
  border-bottom: 0;
}


.request-details, .request-form, .login-form, .request-list {
    background: var(--white);
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: var(--shadow);
    margin-bottom: 1.5rem;
    width: 100%;
    overflow-x: hidden;
}

.status {
    font-size: 0.9rem;
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    display: inline-block;
}

.status-green { background: #a3e635; color: var(--text-color); }
.status-yellow { background: #f4a261; color: var(--white); }
.status-red { background: #e63946; color: var(--white); }

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: none; }
}

@media (max-width: 768px) {

    .main-logo {margin-bottom:30px;}

    header {
      padding: 20px 10px 10px;
      overflow: visible;
    }

    .navbar {
        flex-wrap: wrap;
        padding: 10px;
        position: relative;
    }

    .navbar-toggle {
        display: block;
    }

    .navbar-menu {
        display: none;
        flex-direction: column;
        width: 100%;
        gap: 0.5rem;
        margin-top: 1rem;
        background: var(--white);
        padding: 1rem;
        border-radius: 8px;
        box-shadow: var(--shadow);
    }

    .navbar-menu.active {
    display: flex;
    position: absolute;
    top: 20px;
    width: 200px;
  }

    .navbar-menu.active a {
      font-size: 14px;
    }

    main.container {
        margin: 1rem 0;
        padding: 0 0.5rem;
    }

    h1 {
        font-size: 1.8rem;
    }

    .hero h1 {
        font-size: 1.8rem;
    }

    .hero p {
        font-size: 1rem;
    }

    .form-control {
        font-size: 0.9rem;
    }

    .btn {
        padding: 0.6rem 1rem;
        font-size: 0.9rem;
    }

    .request-grid {
        grid-template-columns: 1fr;
    }

    .request-details, .request-form, .login-form, .request-list {
        padding: 1rem;
    }

    .lang-dropdown {
        font-size: 0.85rem;
        padding: 0.4rem 0.8rem;
    }

    .footer-text {
      margin-bottom: 40px;
    }

    .footer-title {
      margin-bottom: 30px;
    }
}

@media (max-width: 480px) {
    .navbar-brand a {
        font-size: 1.2rem;
    }

    h1 {
        font-size: 1.5rem;
    }

    .hero h1 {
        font-size: 1.5rem;
    }

    .btn {
        padding: 0.5rem 0.8rem;
        font-size: 0.85rem;
    }

    .form-control {
        font-size: 0.85rem;
    }
}

::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f0f0f0;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #3a80d2;
}

/* Ensure modals are on top of their backdrops */
.modal {
    z-index: 1050;
}

.modal-backdrop {
    z-index: 1040;
}
