Spaces:
Running
Running
Update style.css
Browse files
style.css
CHANGED
@@ -1,28 +1,198 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
body {
|
2 |
-
|
3 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
4 |
}
|
5 |
|
6 |
-
|
7 |
-
|
8 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
9 |
}
|
|
|
|
|
|
|
|
|
10 |
|
11 |
-
|
12 |
-
|
13 |
-
|
14 |
-
|
15 |
-
margin-top: 5px;
|
16 |
}
|
17 |
|
18 |
-
|
19 |
-
|
20 |
-
|
21 |
-
|
22 |
-
|
23 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
24 |
}
|
25 |
|
26 |
-
.
|
27 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
28 |
}
|
|
|
|
|
|
|
|
|
|
1 |
+
:root {
|
2 |
+
--phone-body-color: #e0dacd; /* Creamy beige */
|
3 |
+
--dial-plate-bg: linear-gradient(145deg, #d3cabd, #f8f5ee); /* Subtle gradient */
|
4 |
+
--dial-plate-border: #a89d8a;
|
5 |
+
--hole-color: #5c554a; /* Dark brown */
|
6 |
+
--number-color: #403a30;
|
7 |
+
--finger-stop-color: #b0a492; /* Metallic-ish stop */
|
8 |
+
--finger-stop-border: #7d7365;
|
9 |
+
--display-bg: #4a443b; /* Dark display */
|
10 |
+
--display-text: #ffc107; /* Amber text */
|
11 |
+
--button-bg: #795548; /* Brown */
|
12 |
+
--button-text: #ffffff;
|
13 |
+
|
14 |
+
--dial-size: 300px; /* Slightly larger */
|
15 |
+
--hole-size: calc(var(--dial-size) * 0.13);
|
16 |
+
--number-font-size: calc(var(--dial-size) * 0.075); /* Slightly smaller number */
|
17 |
+
}
|
18 |
+
|
19 |
body {
|
20 |
+
display: flex;
|
21 |
+
justify-content: center;
|
22 |
+
align-items: center;
|
23 |
+
min-height: 100vh;
|
24 |
+
background-color: #f0ece3; /* Light background */
|
25 |
+
font-family: 'Orbitron', sans-serif; /* Techy font */
|
26 |
+
overflow: hidden; /* Prevent scrollbars during drag */
|
27 |
+
user-select: none; /* Prevent text selection during drag */
|
28 |
+
-webkit-user-select: none;
|
29 |
+
-moz-user-select: none;
|
30 |
+
-ms-user-select: none;
|
31 |
+
}
|
32 |
+
|
33 |
+
.phone-body {
|
34 |
+
background-color: var(--phone-body-color);
|
35 |
+
padding: 35px;
|
36 |
+
border-radius: 20px;
|
37 |
+
box-shadow: 8px 8px 20px rgba(0,0,0,0.25),
|
38 |
+
inset 0 0 15px rgba(255,255,255,0.3),
|
39 |
+
inset 0 0 10px rgba(0,0,0,0.1);
|
40 |
+
display: flex;
|
41 |
+
flex-direction: column;
|
42 |
+
align-items: center;
|
43 |
+
}
|
44 |
+
|
45 |
+
.display-panel {
|
46 |
+
display: flex;
|
47 |
+
align-items: stretch; /* Make items same height */
|
48 |
+
width: 90%;
|
49 |
+
max-width: 320px;
|
50 |
+
height: 50px;
|
51 |
+
border-radius: 8px;
|
52 |
+
overflow: hidden; /* Clip corners */
|
53 |
+
margin-bottom: 35px;
|
54 |
+
background-color: var(--display-bg);
|
55 |
+
box-shadow: inset 3px 3px 8px rgba(0,0,0,0.5);
|
56 |
+
}
|
57 |
+
|
58 |
+
#dialed-numbers {
|
59 |
+
flex-grow: 1; /* Take available space */
|
60 |
+
color: var(--display-text);
|
61 |
+
font-size: 2em;
|
62 |
+
padding: 5px 15px;
|
63 |
+
display: flex;
|
64 |
+
align-items: center;
|
65 |
+
justify-content: flex-end; /* Numbers align right */
|
66 |
+
letter-spacing: 3px;
|
67 |
+
text-shadow: 0 0 5px rgba(255, 193, 7, 0.5); /* Glow effect */
|
68 |
+
overflow: hidden; /* Prevent long numbers breaking layout */
|
69 |
+
white-space: nowrap;
|
70 |
}
|
71 |
|
72 |
+
#call-button {
|
73 |
+
flex-shrink: 0; /* Don't shrink */
|
74 |
+
width: 60px; /* Fixed width */
|
75 |
+
background-color: var(--button-bg);
|
76 |
+
color: var(--button-text);
|
77 |
+
border: none;
|
78 |
+
border-left: 2px solid rgba(0,0,0,0.2);
|
79 |
+
cursor: pointer;
|
80 |
+
font-size: 1.5em;
|
81 |
+
display: flex;
|
82 |
+
justify-content: center;
|
83 |
+
align-items: center;
|
84 |
+
transition: background-color 0.2s;
|
85 |
}
|
86 |
+
#call-button:hover {
|
87 |
+
background-color: #9c786c;
|
88 |
+
}
|
89 |
+
|
90 |
|
91 |
+
.dial-assembly {
|
92 |
+
position: relative;
|
93 |
+
width: var(--dial-size);
|
94 |
+
height: var(--dial-size);
|
|
|
95 |
}
|
96 |
|
97 |
+
#dial {
|
98 |
+
position: absolute;
|
99 |
+
top: 0;
|
100 |
+
left: 0;
|
101 |
+
width: 100%;
|
102 |
+
height: 100%;
|
103 |
+
background: var(--dial-plate-bg);
|
104 |
+
border-radius: 50%;
|
105 |
+
border: 4px solid var(--dial-plate-border);
|
106 |
+
box-shadow: inset 0 0 15px rgba(0,0,0,0.2), 0 5px 10px rgba(0,0,0,0.2);
|
107 |
+
transform-origin: center center;
|
108 |
+
/* This transition controls the visual return speed */
|
109 |
+
transition: transform 0.55s cubic-bezier(0.15, 0.85, 0.25, 1);
|
110 |
}
|
111 |
|
112 |
+
.dial-center-design {
|
113 |
+
position: absolute;
|
114 |
+
width: 25%;
|
115 |
+
height: 25%;
|
116 |
+
top: 50%;
|
117 |
+
left: 50%;
|
118 |
+
background: radial-gradient(circle, #c8bba8 0%, var(--finger-stop-color) 100%);
|
119 |
+
border-radius: 50%;
|
120 |
+
transform: translate(-50%, -50%);
|
121 |
+
box-shadow: inset 1px 1px 5px rgba(0,0,0,0.4), 0 0 3px rgba(0,0,0,0.2);
|
122 |
+
z-index: 3; /* Above holes/numbers */
|
123 |
+
}
|
124 |
+
|
125 |
+
|
126 |
+
.hole {
|
127 |
+
position: absolute;
|
128 |
+
width: var(--hole-size);
|
129 |
+
height: var(--hole-size);
|
130 |
+
background-color: var(--hole-color);
|
131 |
+
border-radius: 50%;
|
132 |
+
top: 50%; /* Position origin for transform */
|
133 |
+
left: 50%;
|
134 |
+
/* Center the hole using negative margins */
|
135 |
+
margin-left: calc(var(--hole-size) / -2);
|
136 |
+
margin-top: calc(var(--hole-size) / -2);
|
137 |
+
cursor: grab;
|
138 |
+
z-index: 2; /* Above numbers */
|
139 |
+
box-shadow: inset 2px 2px 4px rgba(0,0,0,0.6);
|
140 |
+
/* Actual position set by JS translate */
|
141 |
+
}
|
142 |
+
.hole.dragging {
|
143 |
+
cursor: grabbing;
|
144 |
+
background-color: #7a7061; /* Lighter when dragging */
|
145 |
+
}
|
146 |
+
|
147 |
+
.dial-plate-number {
|
148 |
+
position: absolute;
|
149 |
+
/* Define area based on font size for centering */
|
150 |
+
width: calc(var(--number-font-size) * 1.5);
|
151 |
+
height: calc(var(--number-font-size) * 1.5);
|
152 |
+
top: 50%; /* Position origin for transform */
|
153 |
+
left: 50%;
|
154 |
+
/* Translate -50% of element size to center it on calculated point */
|
155 |
+
transform: translate(-50%, -50%);
|
156 |
+
display: flex;
|
157 |
+
justify-content: center;
|
158 |
+
align-items: center;
|
159 |
+
font-size: var(--number-font-size);
|
160 |
+
font-weight: 700;
|
161 |
+
color: var(--number-color);
|
162 |
+
z-index: 1; /* Below holes */
|
163 |
+
transform-origin: center center; /* Rotation point for text */
|
164 |
+
/* Final position and text rotation set by JS */
|
165 |
+
}
|
166 |
+
|
167 |
+
|
168 |
+
#finger-stop {
|
169 |
+
position: absolute;
|
170 |
+
width: 18px;
|
171 |
+
height: 45px;
|
172 |
+
background: linear-gradient(to bottom, #cac0b2, var(--finger-stop-color));
|
173 |
+
border: 1px solid var(--finger-stop-border);
|
174 |
+
border-radius: 9px 9px 5px 5px; /* Shaped top/bottom */
|
175 |
+
box-shadow: 1px 1px 4px rgba(0,0,0,0.5);
|
176 |
+
z-index: 4; /* Above everything */
|
177 |
+
/* Position & Rotation set by JS */
|
178 |
+
}
|
179 |
+
|
180 |
+
#clear-button {
|
181 |
+
margin-top: 30px;
|
182 |
+
padding: 10px 25px;
|
183 |
+
font-size: 1em;
|
184 |
+
background-color: var(--button-bg);
|
185 |
+
color: var(--button-text);
|
186 |
+
border: none;
|
187 |
+
border-radius: 5px;
|
188 |
+
cursor: pointer;
|
189 |
+
box-shadow: 2px 2px 5px rgba(0,0,0,0.2);
|
190 |
+
transition: background-color 0.2s, transform 0.1s;
|
191 |
+
}
|
192 |
+
#clear-button:hover {
|
193 |
+
background-color: #9c786c;
|
194 |
}
|
195 |
+
#clear-button:active {
|
196 |
+
transform: translateY(1px);
|
197 |
+
box-shadow: 1px 1px 3px rgba(0,0,0,0.2);
|
198 |
+
}
|