/* ======================================
   OUVIDORIA - MOBILE APP-LIKE EXPERIENCE
   ====================================== */

@media (max-width: 768px) {

  /* Box sizing e imagens responsivas para evitar overflow */
  html,
  html *,
  body,
  body * {
    box-sizing: border-box;
  }

  img,
  picture,
  video {
    max-width: 100%;
    height: auto;
    display: block;
  }

  /* Fundo geral */
  body.page {
    margin: 0;
    font-family: "Inter", Arial, sans-serif;
  }

  /* Conteúdo principal */
  .container {
    width: 100%;
    max-width: 720px;
    margin: 0 auto;
    padding: 0 14px 40px;
  }

  .card {
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
    margin-top: 16px;
  }

  .card h1 {
    font-size: 20px;
    text-align: center;
    color: #262D67;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
  }

  /* Grid Stack */
  .grid-2-col {
    grid-template-columns: 1fr !important;
    gap: 16px !important;
  }

  label {
    font-size: 15px;
    font-weight: 600;
    margin-top: 14px;
    display: block;
  }

  input,
  textarea,
  select {
    width: 100%;
    margin-top: 6px;
    padding: 14px;
    font-size: 16px;
    border: 1px solid #ccc;
    border-radius: 10px;
    transition: 0.2s;
  }

  input:focus,
  textarea:focus,
  select:focus {
    outline: none;
    border-color: #4AA4C9;
    box-shadow: 0 0 0 2px rgba(74, 164, 201, 0.3);
  }

  textarea {
    min-height: 120px;
  }

  /* Botões maiores e empilhados */
  /* Botões mais profissionais */
  .btn {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    padding: 14px;
    margin-top: 12px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 500;
  }

  /* Fix for action buttons in table/cards */
  .page.admin .table .btn.btn-icon {
    width: auto;
    display: inline-flex;
    padding: 8px;
    margin: 0;
  }

  .btn:hover {
    background: #3b8bb0;
  }

  .btn-secondary {
    background: #E62228;
  }

  .btn-secondary:hover {
    background: #c81f22;
  }

  .center {
    text-align: center;
    margin-top: 20px;
  }

  .center .btn-dark {
    background: #262D67;
  }

  .center .btn-dark:hover {
    background: #4AA4C9;
  }

  /* Mensagem de ajuda */
  .help {
    font-size: 13px;
    color: #555;
    text-align: center;
    margin-top: 10px;
  }

  /* Espaçamento entre inputs e botões */
  form {
    display: flex;
    flex-direction: column;
    gap: 10px;
  }

  /* Form sections */
  .form-section {
    background: rgba(255, 255, 255, 0.06) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    padding: 14px !important;
    border-radius: 8px;
    margin-bottom: 14px !important;
    border-left: 4px solid #4AA4C9;
  }

  .form-section h3 {
    margin-top: 0;
    margin-bottom: 12px;
    font-size: 14px;
  }

  /* Transição suave na mudança de página */
  body {
    transition: background 0.4s ease, color 0.4s ease;
  }

  /* Ajustes específicos para área administrativa */
  .page.admin .searchbar {
    display: flex;
    flex-direction: column;
    gap: 10px;
  }

  .page.admin .searchbar input,
  .page.admin .searchbar select,
  .page.admin .searchbar button,
  .page.admin .searchbar .btn {
    width: 100%;
    min-width: 0;
  }

  .page.admin .card {
    padding: 14px;
  }

  /* Tornar a tabela responsiva: na menor tela convertemos linhas em blocos */
  .page.admin .table {
    display: block;
    width: 100%;
    overflow: auto;
    -webkit-overflow-scrolling: touch;
  }

  .page.admin .table thead {
    display: none;
  }

  .page.admin .table tbody tr {
    display: block;
    border: 1px solid rgba(0, 0, 0, 0.06);
    margin-bottom: 12px;
    padding: 10px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.02);
  }

  .page.admin .table td {
    display: flex;
    justify-content: space-between;
    /* Side by side */
    align-items: center;
    /* Vertically centered */
    padding: 12px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    white-space: normal;
    text-align: left;
  }

  .page.admin .table td:last-child {
    border-bottom: none;
    justify-content: flex-end;
    padding-top: 16px;
  }

  .page.admin .table td:before {
    content: attr(data-label);
    font-weight: 600;
    margin-right: 16px;
    margin-bottom: 0;
    color: rgba(255, 255, 255, 0.7);
    display: block;
    font-size: 0.9em;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    flex: 1;
    /* Pushes value to right */
    text-align: left;
  }
}