login.html.twig 5.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
  1. {% extends 'base.html.twig' %}
  2. {% block title %}{{ t.page_title }}{% endblock %}
  3. {% block content %}
  4. <style>
  5. /* Κρύβουμε τυχόν sidebar, λίστες κατηγοριών ή αριστερά κουτιά στην οθόνη login */
  6. aside, .categories-sidebar, .sidebar, [class*="category"] {
  7. display: none !important;
  8. }
  9. /* Κάνουμε το κυρίως πεδίο να καταλάβει όλο το πλάτος */
  10. .main-content, .content, main {
  11. width: 100% !important;
  12. grid-column: 1 / -1 !important;
  13. max-width: 100% !important;
  14. }
  15. </style>
  16. <div style="display: flex; align-items: center; justify-content: center; min-height: 70vh; padding: 40px 20px; width: 100%;">
  17. <div style="background: var(--panel-bg, #1e293b); padding: 40px; border-radius: 12px; box-shadow: 0 10px 25px rgba(0,0,0,0.5); border: 1px solid var(--border-color, #334155); width: 100%; max-width: 400px; box-sizing: border-box; text-align: center;">
  18. <h1 style="margin-top: 0; color: var(--primary, #f97316); font-size: 26px; text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 5px;">
  19. {{ t.heading }}
  20. </h1>
  21. <p style="color: var(--text-muted, #94a3b8); font-size: 14px; margin-bottom: 30px;">
  22. {{ t.subheading }}
  23. </p>
  24. {% if error %}
  25. <div style="padding: 12px; border-radius: 6px; margin-bottom: 20px; font-weight: 600; font-size: 13px; background: rgba(239, 68, 68, 0.1); color: #ef4444; border: 1px solid rgba(239, 68, 68, 0.2);">
  26. {{ error }}
  27. </div>
  28. {% endif %}
  29. <form method="POST" action="login.php">
  30. <div style="margin-bottom: 20px; text-align: left;">
  31. <label style="display: block; margin-bottom: 8px; font-weight: 700; font-size: 13px; color: var(--text-muted, #94a3b8); text-transform: uppercase; letter-spacing: 0.5px;">
  32. {{ t.username }}
  33. </label>
  34. <input type="text" name="username" required autofocus style="width: 100%; padding: 12px; background: #0f172a; border: 1px solid var(--border-color, #334155); color: var(--text-main, #f8fafc); border-radius: 6px; box-sizing: border-box; font-family: 'Inter', sans-serif; font-size: 14px; outline: none;">
  35. </div>
  36. <div style="margin-bottom: 20px; text-align: left;">
  37. <label style="display: block; margin-bottom: 8px; font-weight: 700; font-size: 13px; color: var(--text-muted, #94a3b8); text-transform: uppercase; letter-spacing: 0.5px;">
  38. {{ t.password }}
  39. </label>
  40. <input type="password" name="password" required style="width: 100%; padding: 12px; background: #0f172a; border: 1px solid var(--border-color, #334155); color: var(--text-main, #f8fafc); border-radius: 6px; box-sizing: border-box; font-family: 'Inter', sans-serif; font-size: 14px; outline: none;">
  41. </div>
  42. <button type="submit" style="width: 100%; padding: 14px; background: var(--primary, #f97316); color: white; border: none; border-radius: 6px; cursor: pointer; font-weight: 800; font-size: 14px; text-transform: uppercase; transition: 0.2s; margin-bottom: 15px;">
  43. {{ t.btn_login }}
  44. </button>
  45. </form>
  46. <div style="display: flex; align-items: center; text-align: center; margin: 20px 0; color: var(--text-muted, #94a3b8); font-size: 13px; font-weight: 600; text-transform: uppercase;">
  47. <span style="flex: 1; border-bottom: 1px solid var(--border-color, #334155); margin-right: .5em;"></span> OR <span style="flex: 1; border-bottom: 1px solid var(--border-color, #334155); margin-left: .5em;"></span>
  48. </div>
  49. <!-- Σύνδεση με Google -->
  50. <a href="google_auth.php" style="display: flex; align-items: center; justify-content: center; width: 100%; padding: 12px; background: #ffffff; color: #3c4043; border: 1px solid #dadce0; border-radius: 6px; cursor: pointer; font-weight: 600; font-size: 14px; text-decoration: none; box-sizing: border-box;">
  51. <img src="https://upload.wikimedia.org/wikipedia/commons/c/c1/Google_%22G%22_logo.svg" alt="Google Logo" style="width: 18px; height: 18px; margin-right: 10px;">
  52. {{ t.btn_google }}
  53. </a>
  54. <div style="margin-top: 20px; font-size: 14px; color: var(--text-muted, #94a3b8);">
  55. {{ t.register_text }} <a href="register.php" style="color: var(--primary, #f97316); text-decoration: none; font-weight: 700;">{{ t.register_link }}</a>
  56. </div>
  57. <!-- Εναλλαγή Γλώσσας -->
  58. <div style="margin-top: 25px;">
  59. <a href="?lang=el" style="text-decoration: none; font-size: 12px; font-weight: 700; padding: 6px 12px; border-radius: 20px; background: {% if current_lang == 'el' %}var(--primary, #f97316){% else %}rgba(255,255,255,0.05){% endif %}; color: {% if current_lang == 'el' %}white{% else %}var(--text-muted, #94a3b8){% endif %}; border: 1px solid var(--border-color, #334155); margin: 0 4px;">GR</a>
  60. <a href="?lang=en" style="text-decoration: none; font-size: 12px; font-weight: 700; padding: 6px 12px; border-radius: 20px; background: {% if current_lang == 'en' %}var(--primary, #f97316){% else %}rgba(255,255,255,0.05){% endif %}; color: {% if current_lang == 'en' %}white{% else %}var(--text-muted, #94a3b8){% endif %}; border: 1px solid var(--border-color, #334155); margin: 0 4px;">EN</a>
  61. </div>
  62. </div>
  63. </div>
  64. {% endblock %}